rs6000: Fix shrink-wrap-separate for AIX
commit02cc2953725d54509d31018959d32e75c34c9340
authorsegher <segher@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 15 Oct 2016 21:01:43 +0000 (15 21:01 +0000)
committersegher <segher@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 15 Oct 2016 21:01:43 +0000 (15 21:01 +0000)
treed89e56362ed9fd3d49b09d9d54cd79dc4c10ef8b
parente16e12bfb75dede27f339b1646abd19c6a66aa19
rs6000: Fix shrink-wrap-separate for AIX

All out-of-line register save routines need LR, so we cannot wrap the
LR component if there are out-of-line saves.  This didn't show up for
testing on Linux because none of the tests there use out-of-line FPR
saves without also using out-of-line GPR saves, which we did handle.

This patch fixes it, and also cleans up code a little.

* config/rs6000/rs6000.c (rs6000_get_separate_components): Do not
make LR a separately shrink-wrapped component unless savres_strategy
contains all of {SAVE,REST}_INLINE_{GPRS,FPRS,VRS}.  Do not wrap
GPRs unless both {SAVE,REST}_INLINE_GPRS.  Do not disallow all
wrapping when not both {SAVE,REST}_INLINE_GPRS.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@241203 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/config/rs6000/rs6000.c