This is an archive of the discontinued LLVM Phabricator instance.

[llvm-exegesis] Resolve variant classes in analysis.
ClosedPublic

Authored by courbet on Oct 3 2018, 2:30 AM.

Diff Detail

Repository
rL LLVM

Event Timeline

courbet created this revision.Oct 3 2018, 2:30 AM
courbet updated this revision to Diff 168086.Oct 3 2018, 2:31 AM

clang-format

Harbormaster completed remote builds in B23396: Diff 168086.
gchatelet added inline comments.Oct 3 2018, 2:51 AM
tools/llvm-exegesis/lib/Analysis.cpp
27 ↗(On Diff #168086)

You may want to split this function in two functions, the last argument is awkward.

bool IsVariant(const llvm::MCSubtargetInfo &STI, unsigned SchedClassId);
unsigned resolveSchedClassId(const llvm::MCSubtargetInfo &STI, unsigned SchedClassId, const llvm::MCInst &MCI);
tools/llvm-exegesis/lib/Analysis.h
102 ↗(On Diff #168086)

Move the documentation next to the function and add relevant documentation for the struct

106 ↗(On Diff #168086)

move to cc?

107 ↗(On Diff #168086)

newline

courbet updated this revision to Diff 168097.Oct 3 2018, 4:15 AM
courbet marked 4 inline comments as done.

address comments

gchatelet accepted this revision.Oct 3 2018, 4:45 AM
gchatelet added inline comments.
tools/llvm-exegesis/lib/Analysis.h
110 ↗(On Diff #168097)

newline

This revision is now accepted and ready to land.Oct 3 2018, 4:45 AM
courbet updated this revision to Diff 168099.Oct 3 2018, 4:50 AM
courbet marked an inline comment as done.

address comments

This revision was automatically updated to reflect the committed changes.
MaskRay added a subscriber: MaskRay.Oct 3 2018, 8:36 PM

A Release build (where #if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP) is false) does not call writeEscaped and there will be no SBWriteZeroLatency in the output of test/tools/llvm-exegesis/X86/analysis-uops-variant.test

I have removed the second check line to unbreak the test. Please fix it properly:)

Thanks Fangrui, will do, sorry about the breakage.