16-byte stack alignment for X86-64 ELF. Patch by Dan Gohman.
[oota-llvm.git] / lib / Target / X86 / X86Subtarget.cpp
index a864bb69a954d6e572eeff1ae4599a3c1c7af173..ea185b98e82a2316d70dafffe107ad539f319ed1 100644 (file)
@@ -255,6 +255,8 @@ X86Subtarget::X86Subtarget(const Module &M, const std::string &FS, bool is64Bit)
     }
   }
 
-  if (TargetType == isDarwin || TargetType == isCygwin)
+  if (TargetType == isDarwin ||
+      TargetType == isCygwin ||
+      (TargetType == isELF && Is64Bit))
     stackAlignment = 16;
 }