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)
commit57d6de5fd9dba7fa070b8234db457d0f9d323166
tree0099d6b4335ad20f5d39924ee335173da98a3e6b
parentb0c7b617301ef357d19dc4cdf755947443c11f2d
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.

llvm-svn: 166480
llvm/lib/Target/PowerPC/PPCISelLowering.cpp
llvm/lib/Target/PowerPC/PPCISelLowering.h