Use target_endian, not target.arch in cabi_powerpc64

Now target_arch is powerpc64 on both big and little endian, we need to
use target_endian when there are differences in the two ABIs.
This commit is contained in:
Anton Blanchard 2016-02-03 11:36:14 +11:00
parent fc1c1183f3
commit 84e0458c99

View File

@ -158,7 +158,7 @@ fn classify_ret_ty(ccx: &CrateContext, ty: Type) -> ArgType {
}
// The PowerPC64 big endian ABI doesn't return aggregates in registers
if ccx.sess().target.target.arch == "powerpc64" {
if ccx.sess().target.target.target_endian == "big" {
return ArgType::indirect(ty, Some(Attribute::StructRet))
}