This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] Diagnose unaligned atomic for amdgpu
Needs ReviewPublic

Authored by yaxunl on Mar 23 2021, 11:07 AM.

Details

Diff Detail

Event Timeline

yaxunl created this revision.Mar 23 2021, 11:07 AM
yaxunl requested review of this revision.Mar 23 2021, 11:07 AM
yaxunl updated this revision to Diff 528937.Jun 6 2023, 10:50 AM

rebase and simplify code

Herald added a project: Restricted Project. · View Herald TranscriptJun 6 2023, 10:50 AM
Herald added a subscriber: MaskRay. · View Herald Transcript
tra added inline comments.Jun 6 2023, 11:38 AM
clang/lib/Driver/ToolChains/Clang.cpp
7215 ↗(On Diff #528937)

Should it be done from HIPAMDToolChain::addClangWarningOptions ?

That's where Darwin does similar propotion from a waring to an error.

MaskRay added inline comments.Jun 6 2023, 12:01 PM
clang/test/Driver/hip-options.hip
144

Prefer --target= to deprecated (since 3.x) -target

yaxunl marked 2 inline comments as done.Jun 7 2023, 7:44 AM
yaxunl added inline comments.
clang/lib/Driver/ToolChains/Clang.cpp
7215 ↗(On Diff #528937)

will do. Since this option is shared between all AMDGPU toolchains, I will add it to AMDGPUToolChain::addClangWarningOptions and let the derived toolchains call it.

clang/test/Driver/hip-options.hip
144

will fix

yaxunl updated this revision to Diff 529301.Jun 7 2023, 7:48 AM
yaxunl marked 2 inline comments as done.
yaxunl retitled this revision from [HIP] Diagnose unaligned atomic for amdgpu to [AMDGPU] Diagnose unaligned atomic for amdgpu.

revised by Artem's and Fangrui's comments