diff options
author | Bill Wendling <isanbard@gmail.com> | 2007-08-25 00:51:55 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2007-08-25 00:51:55 +0000 |
commit | 48597b4ff85aa6aaa7cb14a8ec9e95c7a42b267c (patch) | |
tree | 7aa22109029a782ed952fc06f387f809776b260e /llvm/lib/CodeGen | |
parent | d8c9cb918273165cfd6e25ecff0f9a94b9e0a591 (diff) | |
download | bcm5719-llvm-48597b4ff85aa6aaa7cb14a8ec9e95c7a42b267c.tar.gz bcm5719-llvm-48597b4ff85aa6aaa7cb14a8ec9e95c7a42b267c.zip |
The personality function might need to be declared as:
.set Lset0,___gxx_personality_v0-.
.long Lset0
on some targets. Make it so!
llvm-svn: 41385
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r-- | llvm/lib/CodeGen/DwarfWriter.cpp | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/llvm/lib/CodeGen/DwarfWriter.cpp b/llvm/lib/CodeGen/DwarfWriter.cpp index 0ade7a25d5d..19aa6c3b930 100644 --- a/llvm/lib/CodeGen/DwarfWriter.cpp +++ b/llvm/lib/CodeGen/DwarfWriter.cpp @@ -2803,11 +2803,24 @@ private: Asm->EmitInt8(DW_EH_PE_pcrel | DW_EH_PE_sdata4); Asm->EOL("Personality (pcrel sdata4)"); - O << TAI->getData32bitsDirective(); - Asm->EmitExternalGlobal((const GlobalVariable *)(Personality)); - O << "-" << TAI->getPCSymbol(); - Asm->EOL("Personality"); - + if (TAI->needsSet()) { + O << "\t.set\t"; + PrintLabelName("set", SetCounter); + O << ","; + Asm->EmitExternalGlobal((const GlobalVariable *)(Personality)); + O << "-" << TAI->getPCSymbol(); + Asm->EOL("Set Personality"); + O << TAI->getData32bitsDirective(); + PrintLabelName("set", SetCounter); + Asm->EOL("Personality"); + ++SetCounter; + } else { + O << TAI->getData32bitsDirective(); + Asm->EmitExternalGlobal((const GlobalVariable *)(Personality)); + O << "-" << TAI->getPCSymbol(); + Asm->EOL("Personality"); + } + Asm->EmitULEB128Bytes(DW_EH_PE_pcrel); Asm->EOL("LSDA Encoding (pcrel)"); Asm->EmitULEB128Bytes(DW_EH_PE_pcrel); |