This is an archive of the discontinued LLVM Phabricator instance.

Allow data prefetch into non-default address space
ClosedPublic

Authored by rampitec on Jul 14 2022, 12:26 PM.

Details

Summary

I am playing with the LoopDataPrefetch pass and found out that it
bails to work with a pointer in a non-zero address space. This
patch adds the target callback to check if an address space is to
be considered for prefetching. Default implementation still only
allows address space 0, so this is NFCI.

This does not currently affect any known targets, but seems to be
generally useful for the future.

Diff Detail

Event Timeline

rampitec created this revision.Jul 14 2022, 12:26 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 14 2022, 12:26 PM
Herald added a subscriber: hiraditya. · View Herald Transcript
rampitec requested review of this revision.Jul 14 2022, 12:26 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 14 2022, 12:26 PM
foad added a comment.Jul 15 2022, 1:54 AM

Seems like a good generalisation to me.

foad accepted this revision.Jul 27 2022, 9:50 AM
foad added reviewers: hfinkel, anemet.

LGTM. (Added a couple of people who were involved in the original PPC version of this pass.)

This revision is now accepted and ready to land.Jul 27 2022, 9:50 AM
This revision was automatically updated to reflect the committed changes.