summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/X86/X86TargetAsmInfo.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Target/X86/X86TargetAsmInfo.cpp')
-rw-r--r--llvm/lib/Target/X86/X86TargetAsmInfo.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/lib/Target/X86/X86TargetAsmInfo.cpp b/llvm/lib/Target/X86/X86TargetAsmInfo.cpp
index b6270108da2..d978eb179de 100644
--- a/llvm/lib/Target/X86/X86TargetAsmInfo.cpp
+++ b/llvm/lib/Target/X86/X86TargetAsmInfo.cpp
@@ -43,8 +43,7 @@ static const char *const x86_asm_table[] = {
"{cc}", "cc",
0,0};
-X86DarwinTargetAsmInfo::X86DarwinTargetAsmInfo(const Triple &Triple)
- : DarwinTargetAsmInfo(Triple) {
+X86DarwinTargetAsmInfo::X86DarwinTargetAsmInfo(const Triple &Triple) {
AsmTransCBE = x86_asm_table;
AssemblerDialect = AsmWriterFlavor;
@@ -55,6 +54,9 @@ X86DarwinTargetAsmInfo::X86DarwinTargetAsmInfo(const Triple &Triple)
if (!is64Bit)
Data64bitsDirective = 0; // we can't emit a 64-bit unit
+ // Leopard and above support aligned common symbols.
+ COMMDirectiveTakesAlignment = Triple.getDarwinMajorNumber() >= 9;
+
if (is64Bit) {
PersonalityPrefix = "";
PersonalitySuffix = "+4@GOTPCREL";
OpenPOWER on IntegriCloud