From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7992 invoked by alias); 31 Dec 2014 12:42:51 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 7943 invoked by uid 48); 31 Dec 2014 12:42:47 -0000 From: "iverbin at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/64412] [regression] ICE in offload compiler: in extract_insn, at recog.c:2327 Date: Wed, 31 Dec 2014 12:42:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: middle-end X-Bugzilla-Version: 5.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: iverbin at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 5.0 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: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-12/txt/msg02995.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D64412 --- Comment #18 from iverbin at gcc dot gnu.org --- (In reply to Uro=C5=A1 Bizjak from comment #17) > The x86 backend did survive many years just fine, so I think offload shou= ld > be fixed to follow approach that generic middle-end takes. The testcase I > posted expands without problems; in this case middle-end knows that symbol > address has to be moved to a register. It looks like offload bypasses > generic expansion functions (that would magically fix this issue). It seems that the problem with offload is that -fPIC option is passed to the offload compiler, but not passed to the host compiler. If I add -fPIC to the host compiler as well, everything is ok. Offload RTL for pic host, pic offload: (insn 8 6 9 4 (set (reg:DI 88) (mem/u/c:DI (const:DI (unspec:DI [ (symbol_ref:DI ("G") ) ] UNSPEC_GOTPCREL)) [0 S8 A8])) addr.c:6 -1 (nil)) Offload RTL for nonpic host, pic offload: (insn 8 6 9 4 (set (reg:CC 17 flags) (compare:CC (mem/f/c:DI (plus:DI (reg/f:DI 82 virtual-stack-vars) (const_int -8 [0xfffffffffffffff8])) [0 p+0 S8 A64]) (symbol_ref:DI ("G") ))) addr.c:6= -1 (nil)) I don't know how -fPIC option affects IR before streaming out, -fdump-tree-optimized are identical for pic/nonpic cases, but .gnu.offload_lto_.decls sections are different. However debug_tree (vnode->decl) for "G" in ipa_write_summaries are identical for pic/nonpic cases. So, the question is, how to figure out what is different in G's declaration= in IR, and how it can affect further expansion? >>From gcc-bugs-return-471989-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Dec 31 12:59:27 2014 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 14020 invoked by alias); 31 Dec 2014 12:59:27 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 13987 invoked by uid 48); 31 Dec 2014 12:59:23 -0000 From: "hjl.tools at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug ipa/64447] [5 Regression] FAIL: gcc.dg/vect/slp-9.c Date: Wed, 31 Dec 2014 12:59:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: ipa X-Bugzilla-Version: 5.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: blocker X-Bugzilla-Who: hjl.tools at gmail dot com X-Bugzilla-Status: RESOLVED X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 5.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_status resolution Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-12/txt/msg02996.txt.bz2 Content-length: 425 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64447 H.J. Lu changed: What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |RESOLVED Resolution|--- |FIXED --- Comment #7 from H.J. Lu --- Fixed by r219120.