This is another TLC patch for separating code for the Darwin and ELF ABIs
authorBill Schmidt <wschmidt@linux.vnet.ibm.com>
Tue, 23 Oct 2012 15:51:16 +0000 (15:51 +0000)
committerBill Schmidt <wschmidt@linux.vnet.ibm.com>
Tue, 23 Oct 2012 15:51:16 +0000 (15:51 +0000)
commit726c23705c056e4d86f0b3d833803f1d43e6eee4
treebf95f2aff0a8964bc8fd6cf231616f1b82c30981
parentf1ec4e4123a8e6d811c072f383399781cfeaa9aa
This is another TLC patch for separating code for the Darwin and ELF ABIs
for the PowerPC target, and factoring the results.  This will ease future
maintenance of both subtargets.

PPCTargetLowering::LowerCall_Darwin_Or_64SVR4() has grown a lot of special-case
code for the different ABIs, making maintenance difficult.  This is getting
worse as we repair errors in the 64-bit ELF ABI implementation, while avoiding
changes to the Darwin ABI logic.  This patch splits the routine into
LowerCall_Darwin() and LowerCall_64SVR4(), allowing both versions to be
significantly simplified.  I've factored out chunks of similar code where it
made sense to do so.  I also performed similar factoring on
LowerFormalArguments_Darwin() and LowerFormalArguments_64SVR4().

There are no functional changes in this patch, and therefore no new test
cases have been developed.

Built and tested on powerpc64-unknown-linux-gnu with no new regressions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166480 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/PowerPC/PPCISelLowering.cpp
lib/Target/PowerPC/PPCISelLowering.h