File tree Expand file tree Collapse file tree 2 files changed +17
-1
lines changed Expand file tree Collapse file tree 2 files changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -328,9 +328,21 @@ class LLVM_LIBRARY_VISIBILITY HurdTargetInfo : public OSTargetInfo<Target> {
328
328
Builder.defineMacro (" _REENTRANT" );
329
329
if (Opts.CPlusPlus )
330
330
Builder.defineMacro (" _GNU_SOURCE" );
331
+ if (this ->HasFloat128 )
332
+ Builder.defineMacro (" __FLOAT128__" );
331
333
}
332
334
public:
333
- using OSTargetInfo<Target>::OSTargetInfo;
335
+ HurdTargetInfo (const llvm::Triple &Triple, const TargetOptions &Opts)
336
+ : OSTargetInfo<Target>(Triple, Opts) {
337
+ switch (Triple.getArch ()) {
338
+ default :
339
+ break ;
340
+ case llvm::Triple::x86:
341
+ case llvm::Triple::x86_64:
342
+ this ->HasFloat128 = true ;
343
+ break ;
344
+ }
345
+ }
334
346
};
335
347
336
348
// Linux target
Original file line number Diff line number Diff line change 6
6
// RUN: %s -o - | FileCheck %s -check-prefix=CHECK-X86
7
7
// RUN: %clang_cc1 -emit-llvm -triple x86_64-unknown-linux-gnu -std=c++11 \
8
8
// RUN: %s -o - | FileCheck %s -check-prefix=CHECK-X86
9
+ // RUN: %clang_cc1 -emit-llvm -triple i386-unknown-hurd-gnu -std=c++11 \
10
+ // RUN: %s -o - | FileCheck %s -check-prefix=CHECK-X86
11
+ // RUN: %clang_cc1 -emit-llvm -triple x86_64-unknown-hurd-gnu -std=c++11 \
12
+ // RUN: %s -o - | FileCheck %s -check-prefix=CHECK-X86
9
13
// RUN: %clang_cc1 -emit-llvm -triple i386-unknown-freebsd -std=c++11 \
10
14
// RUN: %s -o - | FileCheck %s -check-prefix=CHECK-X86
11
15
// RUN: %clang_cc1 -emit-llvm -triple amd64-unknown-freebsd -std=c++11 \
You can’t perform that action at this time.
0 commit comments