diff options
author | Chad Rosier <mcrosier@apple.com> | 2013-02-20 18:03:44 +0000 |
---|---|---|
committer | Chad Rosier <mcrosier@apple.com> | 2013-02-20 18:03:44 +0000 |
commit | 9b5b8b0b9439da2dd4167ece15db7e13d37f461c (patch) | |
tree | fa6f2aaba44a31f1b3b9361f5ad0eaa2d07f95cf /lib/Target/X86/X86RegisterInfo.cpp | |
parent | 2319a2397990c6ae638b79efd43f88135db66d7b (diff) | |
download | external_llvm-9b5b8b0b9439da2dd4167ece15db7e13d37f461c.zip external_llvm-9b5b8b0b9439da2dd4167ece15db7e13d37f461c.tar.gz external_llvm-9b5b8b0b9439da2dd4167ece15db7e13d37f461c.tar.bz2 |
[ms-inline asm] Make the comment a bit more verbose.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175641 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/X86/X86RegisterInfo.cpp')
-rw-r--r-- | lib/Target/X86/X86RegisterInfo.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/Target/X86/X86RegisterInfo.cpp b/lib/Target/X86/X86RegisterInfo.cpp index fbe6331..3b9144d 100644 --- a/lib/Target/X86/X86RegisterInfo.cpp +++ b/lib/Target/X86/X86RegisterInfo.cpp @@ -389,8 +389,12 @@ bool X86RegisterInfo::hasBasePointer(const MachineFunction &MF) const { return false; // When we need stack realignment and there are dynamic allocas, we can't - // reference off of the stack pointer, so we reserve a base pointer. This - // is also true if the function contain MS-style inline assembly. + // reference off of the stack pointer, so we reserve a base pointer. + // + // This is also true if the function contain MS-style inline assembly. We + // do this because if any stack changes occur in the inline assembly, e.g., + // "pusha", then any C local variable or C argument references in the + // inline assembly will be wrong because the SP is not properly tracked. if ((needsStackRealignment(MF) && MFI->hasVarSizedObjects()) || MF.hasMSInlineAsm()) return true; |