Output the correct format for Darwin.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77376 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Bill Wendling 2009-07-28 22:03:50 +00:00
parent f83264b423
commit 1711a7c8cf

View File

@ -41,11 +41,13 @@ PPCDarwinTargetAsmInfo::PPCDarwinTargetAsmInfo(const PPCTargetMachine &TM) :
unsigned
PPCDarwinTargetAsmInfo::PreferredEHDataFormat(DwarfEncoding::Target Reason,
bool Global) const {
if (Reason == DwarfEncoding::Functions && Global)
return (DW_EH_PE_pcrel | DW_EH_PE_indirect | DW_EH_PE_sdata4);
else if (Reason == DwarfEncoding::CodeLabels || !Global)
if ((Reason == DwarfEncoding::Data || Reason == DwarfEncoding::Functions)
&& Global)
return DW_EH_PE_pcrel | DW_EH_PE_indirect | DW_EH_PE_sdata4;
if (Reason == DwarfEncoding::CodeLabels || !Global)
return DW_EH_PE_pcrel;
else
return DW_EH_PE_absptr;
}