Ping. My SIMT patches are now depending on these.
Thanks Andrew On 03/09/2026 14:47, Andrew Stubbs wrote:
Hi all, This updated patch series implements the "MEMs with address vectors" feature that I want to use in AMD GCN, and have previously discussed on gcc@. The motivation is to simplify a new back-end optimization pass I'm working on and plan to post in the coming weeks. The first version of the series was here: https://patchwork.sourceware.org/project/gcc/list/?series=63334 Compared to the first version, there's now a new RTL flag: MEM_INDEPENDENT_P. This is intended to allow the optimization passes to determine if certain optimizations and transformations are safe, although nothing actually needs that yet. The GCN backend now sets this flag on all store instructions that use address vectors. The first patch, in this series, is the middle-end enablement and documentation changes, including the new flag. The second patch converts the amdgcn back-end to use the new scheme, without adding any real new features. It depends on the INSN_BASE_REG_CLASS patch I posted previously (still in review, pinged this week) to run correctly. The third and final patch demonstrates how I can use the new MEM to extend my machine description without writing whole new insns for the vector modes, just for them to evaluate to the same assembler code in the end. OK for mainline? My experimental SIMT implementation, that uses this new feature extensively, should be ready to post in the next week or so, so I'd really appreciate getting this series decided soon. Thanks Andrew Stubbs (3): rtl: Allow "(mem:<vecmode> (reg:<vecmode>))" amdgcn: Implement "(mem (reg:<vecmode>))" amdgcn: Add vector atomics gcc/config/gcn/constraints.md | 49 ++- gcc/config/gcn/gcn-protos.h | 10 +- gcc/config/gcn/gcn-valu.md | 758 +++++++++++++--------------------- gcc/config/gcn/gcn.cc | 529 +++++++++++++----------- gcc/config/gcn/gcn.h | 1 + gcc/config/gcn/gcn.md | 123 +++--- gcc/doc/rtl.texi | 23 ++ gcc/doc/tm.texi | 13 +- gcc/emit-rtl.cc | 30 +- gcc/explow.cc | 12 +- gcc/recog.cc | 4 +- gcc/rtl.h | 7 +- gcc/rtlanal.cc | 4 +- gcc/simplify-rtx.cc | 5 +- gcc/target.def | 13 +- gcc/targhooks.cc | 4 +- gcc/targhooks.h | 3 +- 17 files changed, 801 insertions(+), 787 deletions(-)
