This is an archive of the discontinued LLVM Phabricator instance.

[esan|cfrag] Create the cfrag struct array for the runtime
ClosedPublic

Authored by zhaoqin on May 25 2016, 9:47 PM.

Details

Diff Detail

Event Timeline

zhaoqin updated this revision to Diff 58561.May 25 2016, 9:47 PM
zhaoqin retitled this revision from to [esan|cfrag] Extend ToolInfo for the cache-fragmentation tool.
zhaoqin updated this object.
zhaoqin added a reviewer: aizatsky.
zhaoqin added subscribers: zhaoqin, llvm-commits, eugenis and 3 others.
zhaoqin updated this revision to Diff 58563.May 25 2016, 10:01 PM

fix minor error

zhaoqin updated this revision to Diff 58565.May 25 2016, 10:04 PM

fix the review range

zhaoqin updated this revision to Diff 58681.May 26 2016, 1:20 PM

remove disable load/store instrumentation

aizatsky added inline comments.May 26 2016, 3:13 PM
lib/Transforms/Instrumentation/EfficiencySanitizer.cpp
295

Do you need a counter for ignored structs?

301

CounterNameRef

345

Please don't reuse the local. There's absolutely no need, but will make reading/breaking this code more difficult.

zhaoqin updated this revision to Diff 59234.Jun 1 2016, 9:31 AM
zhaoqin marked 3 inline comments as done.

PTAL

zhaoqin retitled this revision from [esan|cfrag] Extend ToolInfo for the cache-fragmentation tool to [esan|cfrag] Create the cfrag struct array for the runtime.Jun 1 2016, 9:31 AM
zhaoqin updated this object.
zhaoqin added inline comments.Jun 1 2016, 11:43 AM
lib/Transforms/Instrumentation/EfficiencySanitizer.cpp
295

those Struct are special struct like struct without a body, so does not really need remember how many unless for stats purposes.
Add stats for it.

bruening accepted this revision.Jun 1 2016, 7:49 PM
bruening edited edge metadata.
bruening added inline comments.
lib/Transforms/Instrumentation/EfficiencySanitizer.cpp
249

nit: . or : at end

305

nit: NumIgnoredStructs vs NumOfStructs: maybe remove the Of for consistency ("NumOf" sounds weird to me btw: "NumberOfX" or "NumX" seem more natural, though I see "NumOf" in other LLVM source files.)

325

nit: 2 grammar issues

352

nit: inconsistent: others have .

This revision is now accepted and ready to land.Jun 1 2016, 7:49 PM
zhaoqin updated this revision to Diff 59392.Jun 2 2016, 8:52 AM
zhaoqin marked 3 inline comments as done.
zhaoqin edited edge metadata.

Final

vitalybuka added inline comments.Jun 2 2016, 10:29 AM
lib/Transforms/Instrumentation/EfficiencySanitizer.cpp
95

Maybe try to put everything above into namespace {} and remove static?

319

git clang-format -f origin --style=file

This revision was automatically updated to reflect the committed changes.