Commit Graph

12 Commits

Author SHA1 Message Date
Sylvestre Ledru
7cbba7174d Bug 1337358 - Converts for(...; ...; ...) loops to use the new range-based loops in C++11 in tools/ r=froydnj
MozReview-Commit-ID: GdeCzDXjzzg
2017-02-08 12:04:50 +01:00
Kirti Singla
e3d070aa48 Bug 1301627 - Change the name of commented variables when calling perf_event_open. r=erahm 2016-10-23 10:10:00 -07:00
Chris Peterson
60b41ef447 Bug 1236393 - Annotate intentional switch fallthrough to suppress -Wimplicit-fallthrough warning in tools/power/rapl.cpp. r=njn
tools/power/rapl.cpp:331:7 [-Wimplicit-fallthrough] unannotated fall-through between switch labels
2015-11-23 22:41:07 -08:00
Chris Peterson
da943680c3 Bug 1222887 - Suppress -Wunreachable-code warning in tools/power. r=njn
tools/power/rapl.cpp:844:5 [-Wunreachable-code] code will never be executed

clang reports a -Wunreachable-code warning for sigemptyset() because Darwin's sigemptyset() is a macro that always returns 0. Thus `if (sigemptyset(&sa.sa_mask) < 0)` is always false and `Abort("sigemptyset() failed")` is never called. Linux's sigemptyset() can return 0 or -1. The extra parens around (0) suppress the clang warning.
2015-11-09 01:03:54 -08:00
Nicholas Nethercote
bcb3f42ed7 Bug 1203811 - Clarify two error messages in tools/power/rapl. r=heycam. 2015-09-10 23:12:31 -07:00
Nicholas Nethercote
9035fde2c6 Bug 1203834 - Fix's rapl's handling of unsupported power domains. r=glandium.
The "gpu" and "ram" domains aren't supported by all platforms. rapl has a
special constant |kUnsupported_j| to represent this on Linux, but I
accidentally have a minus sign in front of it in several places, which means
that instead of printing "n/a" for unsupported planes we always print "1.0".

I think this happened because I used to hardwire -1 in there and then I later
changed it to a constant but forgot to remove the minus signs.

It sure would be nice to have automated testing for this stuff, but I don't see
how to do it.
2015-09-10 23:12:20 -07:00
Nicholas Nethercote
b131634337 Bug 1201811 (part 2) - Don't print distribution stats if there was only 1 sample. r=erahm. 2015-09-04 01:45:13 -07:00
Nicholas Nethercote
a20a81cb5c Bug 1201811 (part 1) - Don't use integer arithmetic when summing totals in rapl. r=erahm. 2015-09-04 01:04:46 -07:00
Nicholas Nethercote
e18487ea21 Bug 1198137 (follow-up) - Add a missing #include to unbreak Mac OS builds on a CLOSED TREE. r=me 2015-08-26 11:48:08 +10:00
Nicholas Nethercote
a8a4584340 Bug 1198137 - Add some summary stats to tool/power/rapl's output. r=erahm.
"mean" is most useful, then "min" and "max". The rest are moderately useful.
2015-08-25 18:11:03 -07:00
Nicholas Nethercote
4fab17430d Bug 1197694 - fflush() rapl output so it always appears immediately. r=erahm. 2015-08-24 15:59:37 -07:00
Nicholas Nethercote
e1aa9c6d8b Bug 1194560 - Add tools/power/rapl, a RAPL-reading program for power profiling. r=erahm,glandium. 2015-08-19 22:25:30 -07:00