MSP430: Implement TARGET_MEMORY_MOVE_COST
authorJozef Lawrynowicz <jozef.l@mittosystems.com>
Fri, 13 Nov 2020 15:35:33 +0000 (15:35 +0000)
committerJozef Lawrynowicz <jozef.l@mittosystems.com>
Fri, 13 Nov 2020 15:36:29 +0000 (15:36 +0000)
commit953587a2b0fb171b94685f2808e906adb66d4f0b
tree8eae617ef8d39db229893352a655a29a53d4fc68
parent602c6cfc79ce4ae61e277107e0a60079c1a93a97
MSP430: Implement TARGET_MEMORY_MOVE_COST

The cycle and size cost of a MOV instruction in different addressing
modes can be used to calculate the TARGET_MEMORY_MOVE_COST relative to
TARGET_REGISTER_MOVE_COST.

gcc/ChangeLog:

* config/msp430/msp430.c (struct single_op_cost): New struct.
(struct double_op_cost): Likewise.
(TARGET_REGISTER_MOVE_COST): Don't define but add comment.
(TARGET_MEMORY_MOVE_COST): Define to...
(msp430_memory_move_cost): New function.
(BRANCH_COST): Don't define but add comment.
gcc/config/msp430/msp430.c