From owner-freebsd-ppc@freebsd.org Sun Jul 22 18:54:07 2018 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4A2C11052F5D for ; Sun, 22 Jul 2018 18:54:07 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2610:1c1:1:6074::16:84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E93E4803DC for ; Sun, 22 Jul 2018 18:54:06 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by freefall.freebsd.org (Postfix) id C893B12727; Sun, 22 Jul 2018 18:54:06 +0000 (UTC) Delivered-To: powerpc@localmail.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mx1.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by freefall.freebsd.org (Postfix) with ESMTPS id AC68A12725 for ; Sun, 22 Jul 2018 18:54:06 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.ysv.freebsd.org (mxrelay.ysv.freebsd.org [IPv6:2001:1900:2254:206a::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.ysv.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7B1CD803D9 for ; Sun, 22 Jul 2018 18:54:06 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.ysv.freebsd.org (Postfix) with ESMTPS id B08FE20AB8 for ; Sun, 22 Jul 2018 18:54:05 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id w6MIs52n023053 for ; Sun, 22 Jul 2018 18:54:05 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id w6MIs5G5023052 for powerpc@FreeBSD.org; Sun, 22 Jul 2018 18:54:05 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: powerpc@FreeBSD.org Subject: [Bug 225629] powerpc64 (POWER9) segfaults randomly (e.g., building lang/gcc5) Date: Sun, 22 Jul 2018 18:54:03 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: marklmi26-fbsd@yahoo.com X-Bugzilla-Status: In Progress X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: ppc@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Jul 2018 18:54:07 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D225629 --- Comment #24 from Mark Millard --- (In reply to Gerald Pfeifer from comment #23) The problem is with the name vec_step which has a special use in system-clang that conflicts with gcc's tree-vect-loop.c local use of the name: namespace pollution (via OpenCL support requiring such and being enabled, apparently). Anything that avoids the name conflict is a work around. clang for "with altivec/OpenCL support included" defines the notations: ( 3 lines from llvm/tools/clang/lib/Parse/ParseExpr.cpp ) [OpenCL 1.1 6.11.12] vec_step built-in function: vec_step ( expressions ) vec_step ( type-name ) and has error messages like (2 more lines from there): Not a typeof/sizeof/alignof/vec_step expression! Not a sizeof/alignof/vec_step expression! (and examples via tools/clang/include/clang/Basic/DiagnosticSemaKinds.td ) invalid application of '%select{sizeof|alignof|vec_step|__builtin_omp_required_simd_align}0' to an 'vec_step' requires built-in scalar or vector type, %0 invalid As I understand, telling clang -mno-altivec avoids vec_step being defined by clang (via lack of OpenCL support for such) and so avoids needing to rename the local variable in gcc's tree-vect-loop.c . As far as I can tell the gcc code should be valid but system-clang as configured by default makes it not so. I disagree with the "bug" aspect of "Work-around for bug in tree-vect-loop.c". Presuming there is a reason to have OpenCL support enabled in system- clang, I expect that the conditional: CFLAGS+=3D -mno-altivec is appropriate. Otherwise disabling OpenCL support in system-clang for powerpc64 would avoid vec_step ending up as an unavailable name. (I do not know if altivec can be enabled but still have OpenCL support disabled via normal configuration controls for system-clang.) -mno-altivec would not be limited to gcc6 as long as gcc happens to use the name vec_step in its tree-vect-loop.c . I've not checked gcc8 yet, nor have I checked gcc9-devel . gcc7 had the usage and so suffered the issue. --=20 You are receiving this mail because: You are on the CC list for the bug.=