https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118241

--- Comment #7 from Jeffrey A. Law <law at gcc dot gnu.org> ---
Ah nuts!  My mistake, I conflated this issue which is "prefetch" with the other
issue in the "prefetchi" space.  "prefetchi" is broken and likely requires a
deeper fix than what we need here.

I don't see a good path for Andrew's suggestion.  The "prefetch" pattern name
is special and does not include a mode.  So there's can be one and only one. 
That in turn means that there's no way to support different mode operands,
which is important as a pointer might be SI or DI.  So while we could have a
prefetch expander, its operands would continue to be modeless and would then
match a X mode on their associated insn.  I'm not sure that's an improvement
over what we've currently got.

The most straightforward path here is to tighten up the operands which probably
needs to be done anyway.  I think the biggest question is whether or not we try
to support offsets.  They don't seem difficult, we just need to reject those
where the bottom 4 bits are nonzero.  I'll play a bit with that to see if there
are any surprises.

Reply via email to