This is an archive of the discontinued LLVM Phabricator instance.

[clang][nfc] Split getOrCheckAMDGPUCodeObjectVersion
AbandonedPublic

Authored by JonChesterfield on Apr 22 2021, 3:42 PM.

Details

Reviewers
yaxunl
Summary

[clang][nfc] Split getOrCheckAMDGPUCodeObjectVersion

Separates detection of deprecated or invalid code object version from
returning the version. Alternative to D101077.

Diff Detail

Event Timeline

JonChesterfield requested review of this revision.Apr 22 2021, 3:42 PM
Herald added a project: Restricted Project. · View Herald TranscriptApr 22 2021, 3:42 PM

I'm not very pleased with this. There's too much state to move around when representing the failure and the control flow is probably harder to read than it was in the original. May take another pass at it.

yaxunl accepted this revision.Apr 22 2021, 3:49 PM

nice. Thanks.

This revision is now accepted and ready to land.Apr 22 2021, 3:49 PM

I'm not very pleased with this. There's too much state to move around when representing the failure and the control flow is probably harder to read than it was in the original. May take another pass at it.

I am OK with this. If you would like to try more pls go ahead.

JonChesterfield abandoned this revision.EditedApr 22 2021, 3:50 PM

Abandoning this. Unacceptably ugly, will revise D101077 in a slightly different direction.

edit: love the race condition in the comments, just testing an alternative now

  • factor out last arg wins
This revision is now accepted and ready to land.Apr 22 2021, 3:57 PM
JonChesterfield abandoned this revision.Apr 23 2021, 12:44 PM