aboutsummaryrefslogtreecommitdiffhomepage
path: root/third_party
diff options
context:
space:
mode:
authorGravatar skcms-skia-autoroll@skia-buildbots.google.com.iam.gserviceaccount.com <skcms-skia-autoroll@skia-buildbots.google.com.iam.gserviceaccount.com>2018-04-23 15:41:39 +0000
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-04-23 16:08:10 +0000
commiteb17254754255753ba37518190a93677290f84bf (patch)
tree59516265b6a165f7fb6bf1b9e3d971a4206fc6dc /third_party
parent4231401dba47ff6e671b7cf1e9d193aa3feac754 (diff)
Roll skia/third_party/skcms 71966da..17d4b82 (1 commits)
https://skia.googlesource.com/skcms.git/+log/71966da..17d4b82 2018-04-23 mtklein@chromium.org SKCMS_PROFILE support on ARMv7 The AutoRoll server is located here: https://skcms-skia-roll.skia.org Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+/master/autoroll/README.md If the roll is causing failures, please contact the current sheriff, who should be CC'd on the roll, and stop the roller if necessary. TBR=stani@google.com Change-Id: I342ffdfcbd1c4588f031f574d7fef939b51abd3b Reviewed-on: https://skia-review.googlesource.com/122989 Reviewed-by: skcms-skia-autoroll <skcms-skia-autoroll@skia-buildbots.google.com.iam.gserviceaccount.com> Commit-Queue: Mike Klein <mtklein@google.com>
Diffstat (limited to 'third_party')
-rw-r--r--third_party/skcms/src/Transform.c23
-rwxr-xr-xthird_party/skcms/version.sha12
2 files changed, 17 insertions, 8 deletions
diff --git a/third_party/skcms/src/Transform.c b/third_party/skcms/src/Transform.c
index 204bb9f1b7..4edff05d43 100644
--- a/third_party/skcms/src/Transform.c
+++ b/third_party/skcms/src/Transform.c
@@ -22,17 +22,26 @@
#include <stdio.h>
#include <stdlib.h>
+ #if defined(__arm__)
+ #include <time.h>
+ static const char* now_units = "ticks";
+ static uint64_t now() { return (uint64_t)clock(); }
+ #else
+ static const char* now_units = "cycles";
+ static uint64_t now() { return __builtin_readcyclecounter(); }
+ #endif
+
#define M(op) +1
- static uint64_t cycles[FOREACH_Op(M)];
+ static uint64_t counts[FOREACH_Op(M)];
#undef M
static void profile_dump_stats() {
#define M(op) #op,
static const char* names[] = { FOREACH_Op(M) };
#undef M
- for (int i = 0; i < ARRAY_COUNT(cycles); i++) {
- if (cycles[i]) {
- fprintf(stderr, "%16s: %12llu cycles\n", names[i], cycles[i]);
+ for (int i = 0; i < ARRAY_COUNT(counts); i++) {
+ if (counts[i]) {
+ fprintf(stderr, "%16s: %12llu %s\n", names[i], counts[i], now_units);
}
}
}
@@ -44,11 +53,11 @@
if (!current) {
atexit(profile_dump_stats);
} else {
- *current += __builtin_readcyclecounter() - start;
+ *current += now() - start;
}
- current = &cycles[op];
- start = __builtin_readcyclecounter();
+ current = &counts[op];
+ start = now();
return op;
}
#else
diff --git a/third_party/skcms/version.sha1 b/third_party/skcms/version.sha1
index eb875605a8..350e5edb85 100755
--- a/third_party/skcms/version.sha1
+++ b/third_party/skcms/version.sha1
@@ -1 +1 @@
-71966da6705d6e49b518e56bb829708b797b67b9 \ No newline at end of file
+17d4b822a04a12b896fdbdbd6a9ae29ac0d8ccdc \ No newline at end of file