]> git.ipfire.org Git - thirdparty/gcc.git/commit
s390: Implement TARGET_INSN_COST [PR115835]
authorStefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
Tue, 11 Mar 2025 07:59:15 +0000 (08:59 +0100)
committerStefan Schulze Frielinghaus <stefansf@gcc.gnu.org>
Tue, 11 Mar 2025 07:59:15 +0000 (08:59 +0100)
commit229f4f040485c0c05cfb707b30c9b983ed1f95d3
treef4ae6be11ff00ab72fcccdcf5ae0be6557723a66
parentc39b0d4faedd432c85ba5c737ebe9d41aad7dca1
s390: Implement TARGET_INSN_COST [PR115835]

Currently insn_cost() only considers the source part of a SET.
Implement TARGET_INSN_COST in order to also take the destination into
account.  This may make a difference in case of a MEM where the address
is a SYMBOL_REF.

Fixes testsuite/gcc.target/s390/section-anchors.c.

gcc/ChangeLog:

PR target/115835
* config/s390/s390.cc (s390_insn_cost): Implement.
(TARGET_INSN_COST): Define.
gcc/config/s390/s390.cc