This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU][MC][GFX10] Improved dpp8 errors handling
ClosedPublic

Authored by dp on Jan 15 2021, 2:17 AM.

Diff Detail

Event Timeline

dp created this revision.Jan 15 2021, 2:17 AM
dp requested review of this revision.Jan 15 2021, 2:17 AM
Herald added a project: Restricted Project. · View Herald TranscriptJan 15 2021, 2:17 AM
rampitec added inline comments.Jan 15 2021, 10:48 AM
llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp
7274

Just use getLoc() here? Loc does not seem to be used otherwise.

dp marked an inline comment as done.Jan 15 2021, 11:26 AM
dp added inline comments.
llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp
7274

The intention was to save the location before calling parseAbsoluteExpression. If the expression value is out of bounds, and we call getLoc() later, we will refer an incorrect error position (the next token after the expression).

This revision is now accepted and ready to land.Jan 15 2021, 11:34 AM
This revision was automatically updated to reflect the committed changes.
dp marked an inline comment as done.