File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
llvm/include/llvm/TargetParser Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 33// RUN: %clang -### --target=riscv64-linux %s 2>&1 | FileCheck --check-prefix=NODESC %s
44// RUN: %clang -### --target=x86_64-linux -mtls-dialect=gnu %s 2>&1 | FileCheck --check-prefix=NODESC %s
55
6+ /// Android supports TLSDESC by default on RISC-V
7+ /// TLSDESC is not on by default in Linux, even on RISC-V, and is covered above
8+ // RUN: %clang -### --target=riscv64-android %s 2>&1 | FileCheck --check-prefix=DESC %s
9+
610/// LTO
711// RUN: %clang -### --target=riscv64-linux -flto -mtls-dialect=desc %s 2>&1 | FileCheck --check-prefix=LTO-DESC %s
812// RUN: %clang -### --target=riscv64-linux -flto %s 2>&1 | FileCheck --check-prefix=LTO-NODESC %s
Original file line number Diff line number Diff line change @@ -1035,10 +1035,7 @@ class Triple {
10351035
10361036 // / True if the target supports both general-dynamic and TLSDESC, and TLSDESC
10371037 // / is enabled by default.
1038- bool hasDefaultTLSDESC () const {
1039- // TODO: Improve check for other platforms, like Android, and RISC-V
1040- return false ;
1041- }
1038+ bool hasDefaultTLSDESC () const { return isAndroid () && isRISCV64 (); }
10421039
10431040 // / Tests whether the target uses -data-sections as default.
10441041 bool hasDefaultDataSections () const {
You can’t perform that action at this time.
0 commit comments