Currently ELFv2 is mostly set, but some places still default to ELFv1.
While this mostly works, it breaks in particular when lld is used with LTO,
as reported in https://github.com/llvm/llvm-project/issues/46697.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Time | Test | |
---|---|---|
60,910 ms | x64 debian > Clang.Driver::fsanitize.c Script:
--
: 'RUN: at line 1'; /var/lib/buildkite-agent/builds/llvm-project/build/bin/clang --target=x86_64-linux-gnu -fsanitize=undefined -fsanitize-trap=undefined /var/lib/buildkite-agent/builds/llvm-project/clang/test/Driver/fsanitize.c -### 2>&1 | /var/lib/buildkite-agent/builds/llvm-project/build/bin/FileCheck /var/lib/buildkite-agent/builds/llvm-project/clang/test/Driver/fsanitize.c --check-prefix=CHECK-UNDEFINED-TRAP
| |
510 ms | x64 debian > LLVM.CodeGen/PowerPC::ppc64-elf-abi.ll Script:
--
: 'RUN: at line 1'; /var/lib/buildkite-agent/builds/llvm-project/build/bin/llc -verify-machineinstrs -mtriple=powerpc64-unknown-linux-gnu < /var/lib/buildkite-agent/builds/llvm-project/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll | /var/lib/buildkite-agent/builds/llvm-project/build/bin/FileCheck /var/lib/buildkite-agent/builds/llvm-project/llvm/test/CodeGen/PowerPC/ppc64-elf-abi.ll -check-prefix=CHECK-ELFv1
| |
100 ms | x64 debian > LLVM.CodeGen/PowerPC::pr47373.ll Script:
--
: 'RUN: at line 2'; /var/lib/buildkite-agent/builds/llvm-project/build/bin/llc -mtriple=powerpc64-unknown-freebsd13.0 -verify-machineinstrs -mcpu=ppc64 -ppc-asm-full-reg-names < /var/lib/buildkite-agent/builds/llvm-project/llvm/test/CodeGen/PowerPC/pr47373.ll | /var/lib/buildkite-agent/builds/llvm-project/build/bin/FileCheck /var/lib/buildkite-agent/builds/llvm-project/llvm/test/CodeGen/PowerPC/pr47373.ll
|
Event Timeline
Comment Actions
Nice catch!
I'm not a LLVM maintainer but from FreeBSD PowerPC side I agree with the changes, only added two suggestions that could improve code readability
clang/lib/Basic/Targets/PPC.h | ||
---|---|---|
428 | The comparison Triple.getOSMajorVersion() == 0 works, but I think Triple.getOSVersion().empty() would better describe the intent | |
llvm/lib/Target/PowerPC/PPCTargetMachine.cpp | ||
237 | Same here, it could be TT.getOSVersion().empty() instead of TT.getOSMajorVersion() == 0 |
Comment Actions
Yeah I think that is probably the better option, hope @pkubaj and @adalava agree with that?
As Brad's version covers both FreeBSD and OpenBSD, and also updates a bunch of unit tests, which this review appears to break (see the Unit Tests https://reviews.llvm.org/harbormaster/unit/214420/).