diff options
author | Evan Cheng <evan.cheng@apple.com> | 2011-08-24 22:31:37 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2011-08-24 22:31:37 +0000 |
commit | 5fbe5e783ee0c5ae27c17490a752d7e603e84ed2 (patch) | |
tree | 3b0249c8a909dd3d5bd28c461f317317946655d3 /lib/MC/MCDwarf.cpp | |
parent | 070260cb29ca9024d4fa1d3aabd6c8320b747f5e (diff) | |
download | llvm-5fbe5e783ee0c5ae27c17490a752d7e603e84ed2.tar.gz llvm-5fbe5e783ee0c5ae27c17490a752d7e603e84ed2.tar.bz2 llvm-5fbe5e783ee0c5ae27c17490a752d7e603e84ed2.tar.xz |
Some autoconf tests use module level inline asm to test compiler's handling of
.cfi_startproc. e.g. libffi:
$ cat confopt.c
asm (".cfi_startproc\n\t.cfi_endproc");
int main () { return 0; }
Teach MC / dwarf emission to handle these cfi directives which essentially
create an empty frame.
rdar://10017184
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138504 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/MC/MCDwarf.cpp')
-rw-r--r-- | lib/MC/MCDwarf.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/MC/MCDwarf.cpp b/lib/MC/MCDwarf.cpp index 06ce502d57..b57fd9a13b 100644 --- a/lib/MC/MCDwarf.cpp +++ b/lib/MC/MCDwarf.cpp @@ -895,7 +895,7 @@ MCSymbol *FrameEmitterImpl::EmitFDE(MCStreamer &streamer, const MCObjectFileInfo *MOFI = context.getObjectFileInfo(); bool verboseAsm = streamer.isVerboseAsm(); - if (!MOFI->isFunctionEHFrameSymbolPrivate() && IsEH) { + if (IsEH && frame.Function && !MOFI->isFunctionEHFrameSymbolPrivate()) { MCSymbol *EHSym = context.GetOrCreateSymbol(frame.Function->getName() + Twine(".eh")); streamer.EmitEHSymAttributes(frame.Function, EHSym); |