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

--- Comment #6 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to rsand...@gcc.gnu.org from comment #5)
> ivopts does have code to treat ifn pointer arguments specially,
> see get_mem_type_for_internal_fn &co.  But like Kewen says,
> it's still only based on the mode.

But the dump quoted says 'Type: POINTER ARGUMENT ADDRESS' which means
that doesn't work as desired.  That is, the use is classified wrongly
and the above function only seems to be useful to get the mode of
the memory access done by the internal function?

USE_PTR_ADDRESS doesn't seem to be a very good match to capture
constraints for a memory dereference?

> Personally I'd prefer an internal_fn rather than a gimple* though.
> It can be useful to test these things on a possible future statement,
> not just on one that already exists.

Well yes, passing down a gimple * looks like too generic here.  Maybe
use a code_helper so we can pass down MEM_REF for dereference context
and nothing (ERROR_MARK_NODE?) for plain address use?

Reply via email to