This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
This patch moves the instructions for movdi (both 32-bit and 64-bit) into a separate rs6000_output_move_64bit function. As I'm starting to move more stuff to checking the addr_masks instead of doing a lot of if mode == MODE1 || mode == MODE2, etc. I realized that the mult-register types (complex values, long double using IBM double double, etc.) did not have the offset bits set correctly in reg_addr. I also prevented the Altivec load/stores (that give you the free AND with -16) from being generated for multi-register values. I added a function (rs6000_valid_move_p) that replaces the old is operand[0] a register or is operand[1] a register tests. Right now, it generates the same tests, but I may need to add additional conditions in the future. I have done a full bootstrap and make check on a little endian power8 system with no regressions. The next patch will change the MOVDF and MOVDD patterns to use rs6000_output_move_64bit as well. 2018-03-15 Michael Meissner <meissner@linux.vnet.ibm.com> * config/rs6000/rs6000-protos.h (rs6000_output_move_64bit): Add declaration. (rs6000_valid_move_p): Likewise. * config/rs6000/rs6000-output.c (addr_is_xform_p): New helper function to return if an addresses uses X-form (reg+reg). (reg_is_spr_p): New helper function to determine if a register is a SPR. (rs6000_output_move_64bit): New function to return the proper instruction to do a 64-bit move. * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Rework setting offset addresses to assume multi-register values have the proper offset bits set. Do not enable Altivec & -16 on mult-reigster moves. (rs6000_valid_move_p): New function to validate moves. (reg_offset_addressing_ok_p): Add check if the mode and register class support offstable instructions. * config/rs6000/rs6000.md (movdi_internal32): Move instruction literals to rs6000_otuput_move_64bit. Check move validity with rs6000_move_valid_p. (movdi_internal64): Likewise. -- Michael Meissner, IBM IBM, M/S 2506R, 550 King Street, Littleton, MA 01460-6245, USA email: meissner@linux.vnet.ibm.com, phone: +1 (978) 899-4797
Attachment:
ext-addr.patch03b
Description: Text document
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |