This is an archive of the discontinued LLVM Phabricator instance.

[libomptarget][AMDGPU][NFC] Split atmi_memcpy for h2d and d2h
ClosedPublic

Authored by pdhaliwal on Oct 20 2020, 2:12 AM.

Details

Summary

The calls to atmi_memcpy presently determine the direction of copy (host to
device or device to host) by storing pointers in a map during malloc and
looking up the pointers during memcpy. As each call site already knows the
direction, this stash+lookup can be eliminated.

This NFC will be followed by a functional one that deletes those map lookups.

Diff Detail

Event Timeline

pdhaliwal created this revision.Oct 20 2020, 2:12 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 20 2020, 2:12 AM
pdhaliwal requested review of this revision.Oct 20 2020, 2:12 AM
pdhaliwal edited reviewers, added: JonChesterfield, ronlieb; removed: jdoerfert.Oct 20 2020, 2:12 AM
JonChesterfield retitled this revision from [libomptarget][AMDGPU] Split atmi_memcpy for h2d and d2h to [libomptarget][AMDGPU][NFC] Split atmi_memcpy for h2d and d2h.Oct 20 2020, 2:33 AM
JonChesterfield edited the summary of this revision. (Show Details)
pdhaliwal updated this revision to Diff 299314.Oct 20 2020, 2:39 AM

clang-format'ed the changes

JonChesterfield accepted this revision.Oct 20 2020, 2:47 AM

LG, thanks!

This revision is now accepted and ready to land.Oct 20 2020, 2:47 AM
This revision was landed with ongoing or failed builds.Oct 20 2020, 3:29 AM
This revision was automatically updated to reflect the committed changes.