From nobody Wed Dec 29 10:35:32 2021 X-Original-To: ruby@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 7303219271A7 for ; Wed, 29 Dec 2021 10:35:33 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JP78j1Pwqz4pHS for ; Wed, 29 Dec 2021 10:35:33 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 10565234EE for ; Wed, 29 Dec 2021 10:35:33 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 1BTAZXDh005005 for ; Wed, 29 Dec 2021 10:35:33 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 1BTAZWKg005004 for ruby@FreeBSD.org; Wed, 29 Dec 2021 10:35:32 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" From: bugzilla-noreply@freebsd.org To: ruby@FreeBSD.org Subject: maintainer-feedback requested: [Bug 260791] lang/ruby30 (2021Q4) does not compile on Haswell Date: Wed, 29 Dec 2021 10:35:32 +0000 X-Bugzilla-Type: request X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: ruby@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? Message-ID: In-Reply-To: References: X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: FreeBSD-specific Ruby discussions List-Archive: https://lists.freebsd.org/archives/freebsd-ruby List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-ruby@freebsd.org X-BeenThere: freebsd-ruby@freebsd.org MIME-Version: 1.0 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1640774133; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=2gUajAp9JNME4z7rOb5IaAOhcB5uXojAJukxei97DRw=; b=glBl4BDptx2Gk8sLeBSV0YSSzlwj1s7fuNHERgFxDuJ4u7qedrc7xqNDe5hg1TrsTKYEQ8 a1wA6wQnT3BJvSAptMxlFOpuR0OorIML+dVAJ4g55lLIuwf+x2r2iytXO+Ed9FfT0ZhGF4 Mz8pcVY70nyevy+ocklZIkmSrPqxakpJxjVlhANJiHjvfO864ZnTNJs9JQaEbMay9HPryO Okk3sJqGehBQSOIiINEyx+GmRfAQIPXgOjMn1pukOz4Os1Zsj+2aiwXl9Irk0YJIc0gPgb dSwNY3VCqc4jCdkKeRnh/rZ1PzDreLMR0qR4ZM3vSLd/F+FuqIQooYxOGKCmgA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1640774133; a=rsa-sha256; cv=none; b=iLbuJUK3vtle8TbDkAIjSag/8lVt/2jvY5b1SnusLRQvZHuOnKh0ZovS4FhukcQy7kJwb2 teTnxdY+AWmd4UcWn6SSp2ztD1Gc8hIfFXHnSC+PosrGuJT59ht8EoVJ/Hpbd1XOPzxwxN QKYzKxmK88zDXM1msk1K6RFuWEJPAYFRIMZnho5A6bNIZZzG5OH+WM3KKYCVJNLPF52UeN gntwP8n/1ZhOo5CSwmV7DCd7Cu+U6xcc3FQ43zMG/leEr9eFSPYsNJ0QCm3644c/BV1TXr 7dvXLauZ2m/Nk4hbIYcNLLCxbj/uIuXXpabHRlfwN263V6t/sAtK6ej0FBkJww== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N Bugzilla Automation has asked freebsd-ruby (Nobody) for maintainer-feedback: Bug 260791: lang/ruby30 (2021Q4) does not compile on Haswell https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D260791 --- Description --- To reproduce: ------------- set /etc/make.conf: CPUTYPE?=3Dhaswell Error: ------ --- numeric.o --- compiling numeric.c In file included from numeric.c:35: In file included from ./internal/numeric.h:13: ./internal/bits.h:240:26: warning: implicit declaration of function '_lzcnt_u32' is invalid in C99 [-Wimplicit-function-declaration] return (unsigned int)_lzcnt_u32(x); ^ ./internal/bits.h:269:26: warning: implicit declaration of function '_lzcnt_u64' is invalid in C99 [-Wimplicit-function-declaration] return (unsigned int)_lzcnt_u64(x); ^ ./internal/bits.h:455:22: warning: implicit declaration of function '_tzcnt_u32' is invalid in C99 [-Wimplicit-function-declaration] return (unsigned)_tzcnt_u32(x); ^ ./internal/bits.h:477:22: warning: implicit declaration of function '_tzcnt_u64' is invalid in C99 [-Wimplicit-function-declaration] return (unsigned)_tzcnt_u64(x); ^ [...] ld: error: undefined symbol: _lzcnt_u32 >>> referenced by bignum.c >>> bignum.o:(bary_divmod_normal) >>> referenced by bignum.c >>> bignum.o:(rb_absint_size) >>> referenced by bignum.c >>> bignum.o:(rb_absint_numwords) >>> referenced by bignum.c >>> bignum.o:(rb_absint_numwords) >>> referenced by bignum.c >>> bignum.o:(rb_int_parse_cstr) >>> referenced by bignum.c >>> bignum.o:(rb_str2big_poweroftwo) >>> referenced by bignum.c >>> bignum.o:(big2ulong) >>> referenced by bignum.c >>> bignum.o:(big2ulong) >>> referenced by bignum.c >>> bignum.o:(big2ull) >>> referenced by bignum.c >>> bignum.o:(big2ull) >>> referenced 18 more times ld: error: undefined symbol: _tzcnt_u32 >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced by compile.c >>> compile.o:(ibf_load_iseq_each) >>> referenced 66 more times ld: error: undefined symbol: _lzcnt_u64 >>> referenced by numeric.c >>> numeric.o:(rb_int_bit_length) >>> referenced by numeric.c >>> numeric.o:(rb_ulong_isqrt) >>> referenced by numeric.c >>> numeric.o:(rb_int_s_isqrt) >>> referenced by numeric.c >>> numeric.o:(builtin_inline_class_75) >>> referenced by random.c >>> random.o:(random_ulong_limited) >>> referenced by st.c >>> st.o:(rb_st_init_table_with_size) ld: error: undefined symbol: _tzcnt_u64 >>> referenced by string.c >>> string.o:(rb_str_coderange_scan_restartable) >>> referenced by string.c >>> string.o:(rb_str_coderange_scan_restartable) >>> referenced by string.c >>> string.o:(rb_str_coderange_scan_restartable) >>> referenced by string.c >>> string.o:(rb_external_str_new_with_enc) >>> referenced by string.c >>> string.o:(rb_external_str_new_with_enc) >>> referenced by string.c >>> string.o:(enc_strlen) >>> referenced by string.c >>> string.o:(enc_strlen) >>> referenced by string.c >>> string.o:(rb_enc_strlen_cr) >>> referenced by string.c >>> string.o:(rb_enc_cr_str_copy_for_substr) >>> referenced by string.c >>> string.o:(str_nth_len) >>> referenced 5 more times cc: error: linker command failed with exit code 1 (use -v to see invocation) *** [miniruby] Error code 1 Analysis: --------- internal/bits.h fails to include because configure does not f= ind it. Configure does not find it because it does search for it only on certain 'x86_64' etc. machine, but we are 'amd64' machine: configure.ac: AS_CASE("$target_cpu", [x64|x86_64|i[3-6]86*], [ AC_CHECK_HEADERS(x86intrin.h) ]) --- configure:3327: checking target system type configure:3340: result: amd64-portbld-freebsd12 I have no idea which party is wrong here, but adding 'amd64' into configure= .ac solves the matter.