This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] Ignore non-SUnits edges
ClosedPublic

Authored by piotr on Apr 18 2019, 4:26 AM.

Details

Summary

Ignore edges to non-SUnits (e.g. ExitSU) when checking
for low latency instructions.

When calling the function isLowLatencyInstruction(),
an ExitSU could be on the list of successors, not necessarily
a regular SU. In other places in the code there is a check
"Succ->NodeNum >= DAGSize" to prevent further processing of
ExitSU as "Succ->getInstr()" is NULL in such a case.
Also, 8 out of 9 cases of "SUnit *Succ = SuccDep.getSUnit())"
has the guard, so it is clearly an omission here.

Change-Id: Ica86f0327c7b2e6bcb56958e804ea6c71084663b

Diff Detail

Repository
rL LLVM

Event Timeline

piotr created this revision.Apr 18 2019, 4:26 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 18 2019, 4:26 AM
nhaehnle accepted this revision.Apr 18 2019, 6:37 AM

LGTM, with the understanding that the test case which we have in our internal branches will make it upstream.

This revision is now accepted and ready to land.Apr 18 2019, 6:37 AM
This revision was automatically updated to reflect the committed changes.