forked from OSchip/llvm-project
Accept and ignore -Wa,-mbig-obj on COFF targets for gas compatibility
LLVM's integrated assembler will automatically switch to big objects when there are more than 2**16 sections. Patch by Kyra! llvm-svn: 290979
This commit is contained in:
parent
49152b3f06
commit
c1afcd7c79
|
@ -3067,6 +3067,10 @@ static void CollectArgsForIntegratedAssembler(Compilation &C,
|
|||
continue;
|
||||
}
|
||||
|
||||
if (C.getDefaultToolChain().getTriple().isOSBinFormatCOFF() &&
|
||||
Value == "-mbig-obj")
|
||||
continue; // LLVM handles bigobj automatically
|
||||
|
||||
switch (C.getDefaultToolChain().getArch()) {
|
||||
default:
|
||||
break;
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
// RUN: %clang --target=x86_64-windows -c -Wa,-mbig-obj %s 2>&1 | FileCheck %s --check-prefix=WINDOWS
|
||||
// RUN: %clang --target=x86_64-windows -c -Xassembler -mbig-obj %s 2>&1 | FileCheck %s --check-prefix=WINDOWS
|
||||
// RUN: not %clang --target=x86_64-linux -c -Wa,-mbig-obj %s 2>&1 | FileCheck %s --check-prefix=LINUX
|
||||
// RUN: not %clang --target=x86_64-linux -c -Xassembler -mbig-obj %s 2>&1 | FileCheck %s --check-prefix=LINUX
|
||||
// WINDOWS-NOT: argument unused during compilation
|
||||
// LINUX: unsupported argument '-mbig-obj' to option '{{(Wa,|Xassembler)}}'
|
||||
#ifdef _WIN32
|
||||
#warning "produce non-empty output for FileCheck"
|
||||
#endif
|
Loading…
Reference in New Issue