diff options
author | liuhongt <hongtao.liu@intel.com> | 2024-06-24 17:53:22 +0800 |
---|---|---|
committer | liuhongt <hongtao.liu@intel.com> | 2024-06-27 14:14:22 +0800 |
commit | b8153b5417bed02f47354a14ad36100785dfdc47 (patch) | |
tree | 87e96ced384b23ebf8445f97168a0365e3b038e5 /gcc/tree-vectorizer.h | |
parent | 212441e19d8179645efbec6dd98a74eb673734dd (diff) | |
download | gcc-b8153b5417bed02f47354a14ad36100785dfdc47.zip gcc-b8153b5417bed02f47354a14ad36100785dfdc47.tar.gz gcc-b8153b5417bed02f47354a14ad36100785dfdc47.tar.bz2 |
Fix wrong cost of MEM when addr is a lea.
416.gamess regressed 4-6% on x86_64 since my r15-882-g1d6199e5f8c1c0.
The commit adjust rtx_cost of mem to reduce cost of (add op0 disp).
But Cost of ADDR could be cheaper than XEXP (addr, 0) when it's a lea.
It is the case in the PR, the patch adjust rtx_cost to only handle reg
+ disp, for other forms, they're basically all LEA which doesn't have
additional cost of ADD.
gcc/ChangeLog:
PR target/115462
* config/i386/i386.cc (ix86_rtx_costs): Make cost of MEM (reg +
disp) just a little bit more than MEM (reg).
gcc/testsuite/ChangeLog:
* gcc.target/i386/pr115462.c: New test.
Diffstat (limited to 'gcc/tree-vectorizer.h')
0 files changed, 0 insertions, 0 deletions