[Bug target/69034] New: ICE: RTL check: expected elt 1 type 'e' or 'u', have 'i' (rtx unspec) in copy_replacements_1, at reload.c:6323 with -fPIC and "X" asm input

zsojka at seznam dot cz gcc-bugzilla@gcc.gnu.org
Wed Dec 23 18:01:00 GMT 2015


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69034

            Bug ID: 69034
           Summary: ICE: RTL check: expected elt 1 type 'e' or 'u', have
                    'i' (rtx unspec) in copy_replacements_1, at
                    reload.c:6323 with -fPIC and "X" asm input
           Product: gcc
           Version: 6.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zsojka at seznam dot cz
  Target Milestone: ---
              Host: x86_64-pc-linux-gnu
            Target: powerpc64-unknown-linux-gnu

I don't know how much is this related to PR63669 and PR68254.

RTL checking must be enabled.

Compiler output:
$ powerpc64-unknown-linux-gnu-gcc -O -fPIC testcase.c 
testcase.c: In function 'foo':
testcase.c:7:1: internal compiler error: RTL check: expected elt 1 type 'e' or
'u', have 'i' (rtx unspec) in copy_replacements_1, at reload.c:6323
 }
 ^

0xab4996 rtl_check_failed_type2(rtx_def const*, int, int, int, char const*,
int, char const*)
        /repo/gcc-trunk/gcc/rtl.c:802
0xa8412b copy_replacements_1
        /repo/gcc-trunk/gcc/reload.c:6323
0xa83e7f copy_replacements_1
        /repo/gcc-trunk/gcc/reload.c:6323
0xa8b56c copy_replacements
        /repo/gcc-trunk/gcc/reload.c:6294
0xa8b56c find_reloads_address
        /repo/gcc-trunk/gcc/reload.c:5027
0xa93ef6 find_reloads(rtx_insn*, int, int, int, short*)
        /repo/gcc-trunk/gcc/reload.c:2885
0xaafe99 calculate_needs_all_insns
        /repo/gcc-trunk/gcc/reload1.c:1506
0xaafe99 reload(rtx_insn*, int)
        /repo/gcc-trunk/gcc/reload1.c:995
0x920775 do_reload
        /repo/gcc-trunk/gcc/ira.c:5397
0x920775 execute
        /repo/gcc-trunk/gcc/ira.c:5556
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.

Only powerpc64 and aarch64 choke on this testcase in trunk.

$ powerpc64-unknown-linux-gnu-gcc -v                  
Using built-in specs.
COLLECT_GCC=/repo/gcc-trunk/binary-latest-powerpc64/bin/powerpc64-unknown-linux-gnu-gcc
COLLECT_LTO_WRAPPER=/repo/gcc-trunk/binary-trunk-231903-checking-yes-rtl-df-nographite-powerpc64/bin/../libexec/gcc/powerpc64-unknown-linux-gnu/6.0.0/lto-wrapper
Target: powerpc64-unknown-linux-gnu
Configured with: /repo/gcc-trunk//configure --enable-languages=c,c++
--enable-checking=yes,rtl,df --without-cloog --without-ppl --without-isl
--build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu
--target=powerpc64-unknown-linux-gnu
--with-ld=/usr/bin/powerpc64-unknown-linux-gnu-ld
--with-as=/usr/bin/powerpc64-unknown-linux-gnu-as
--with-sysroot=/usr/powerpc64-unknown-linux-gnu --disable-multilib
--disable-libstdcxx-pch
--prefix=/repo/gcc-trunk//binary-trunk-231903-checking-yes-rtl-df-nographite-powerpc64
Thread model: posix
gcc version 6.0.0 20151222 (experimental) (GCC) 


Tested revisions:
r231903 - FAIL
5-branch r231870 - FAIL
4_9-branch r231865 - FAIL
4_8-branch r224828 - FAIL


More information about the Gcc-bugs mailing list