Quuxplusone / LLVMBugzillaTest

0 stars 0 forks source link

Gold 2.24 on ARMv7 Thumb2 fails to self-host Clang/LLVM #27678

Open Quuxplusone opened 8 years ago

Quuxplusone commented 8 years ago
Bugzilla Link PR27679
Status NEW
Importance P normal
Reported by Renato Golin (rengolin@gmail.com)
Reported on 2016-05-08 11:43:30 -0700
Last modified on 2016-05-08 11:46:23 -0700
Version unspecified
Hardware PC Linux
CC adhemerval.zanella@linaro.org, davidxl@google.com, kristof.beyls@arm.com, llvm-bugs@lists.llvm.org, rafael@espindo.la
Fixed by commit(s)
Attachments llvm-tblgen-bad.zip (874017 bytes, application/zip)
llvm-tblgen-good.zip (886609 bytes, application/zip)
Blocks
Blocked by
See also
When using Gold 2.24 on Thumb2, llvm-tlbgen fails. BFD ld of the same version
works fine.

Stack dump:
0.  Program arguments: /home/linaro/devel/llvm/bisect/build2/bin/llvm-tblgen -
gen-intrinsic -I /home/linaro/devel/llvm/bisect/llvm/include/llvm/IR -I
/home/linaro/devel/llvm/bisect/llvm/lib/Target -I
/home/linaro/devel/llvm/bisect/llvm/include
/home/linaro/devel/llvm/bisect/llvm/include/llvm/IR/Intrinsics.td -o
/home/linaro/devel/llvm/bisect/build2/include/llvm/IR/Intrinsics.gen.tmp
Bus error (core dumped)

Luckily, gold is failing to link stage2 llvm-tblgen, instead of stage1 Clang,
which would be a lot harder to pick up.

The main difference seems to be on branch literals, so likely some relocation
problem:

 * GOOD:
bhi.n d4dae
<_ZN12_GLOBAL__N_119RegisterInfoEmitter13runTargetDescERN4llvm11raw_ostreamERNS1_13CodeGenT
...
bl  10315c <_ZN4llvm11raw_ostream5writeEPKcj>
...
b.n d4dc6
<_ZN12_GLOBAL__N_119RegisterInfoEmitter13runTargetDescERN4llvm11raw_ostreamERNS1_13CodeGenTar

 * BAD:

bhi.n d29be
<_ZN12_GLOBAL__N_119RegisterInfoEmitter13runTargetDescERN4llvm11raw_ostreamERNS1_13CodeGenT
...
bl  100d6c <_ZN4llvm11raw_ostream5writeEPKcj>
...
b.n d29d6
<_ZN12_GLOBAL__N_119RegisterInfoEmitter13runTargetDescERN4llvm11raw_ostreamERNS1_13CodeGenTar

Both binaries attached for reference.
Quuxplusone commented 8 years ago

Attached llvm-tblgen-bad.zip (874017 bytes, application/zip): bad tblgen

Quuxplusone commented 8 years ago

Attached llvm-tblgen-good.zip (886609 bytes, application/zip): good tblgen

Quuxplusone commented 8 years ago

Clang/LLVM revision 268875