This is an archive of the discontinued LLVM Phabricator instance.

[OpenMP][NVPTX] Added forward declaration for atomic operations
ClosedPublic

Authored by tianshilei1992 on Jan 20 2021, 1:12 PM.

Details

Summary

Pretty similar to D95058, this patch added forward declaration for
CUDA atomic functions. We already have definitions with right mangled names in
internal CUDA headers so the forward declaration here can work properly.

Diff Detail

Event Timeline

tianshilei1992 created this revision.Jan 20 2021, 1:12 PM
tianshilei1992 requested review of this revision.Jan 20 2021, 1:12 PM
Herald added a project: Restricted Project. · View Herald TranscriptJan 20 2021, 1:12 PM
JonChesterfield added a comment.EditedJan 20 2021, 1:14 PM

Possibly obsolete?

Sorry, misread. I have a nearly-ready patch that turns these into non-template functions and moves them into the .cu

Fine by me too

This revision is now accepted and ready to land.Jan 20 2021, 1:14 PM
openmp/libomptarget/deviceRTLs/nvptx/src/target_impl.h
136

I think these all need to be marked DEVICE

Mark those forward declarations as DEVICE

JonChesterfield accepted this revision.Jan 20 2021, 3:53 PM

Thanks. If you land this I'll rebase D95093 manually

This revision was landed with ongoing or failed builds.Jan 21 2021, 7:37 AM
This revision was automatically updated to reflect the committed changes.