Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(162)

Unified Diff: tests/clock/clock_get_test.c

Issue 23464007: Update glibc revision (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: Correct error checking Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tests/clock/clock_get_test.c
diff --git a/tests/clock/clock_get_test.c b/tests/clock/clock_get_test.c
index 91c7106968c110c13a7e0f68511c5adfe9711512..c084d58c49529d570a6c512fbe0b67893f85672b 100644
--- a/tests/clock/clock_get_test.c
+++ b/tests/clock/clock_get_test.c
@@ -7,6 +7,7 @@
#include <inttypes.h>
#include <stdio.h>
#include <time.h>
+#include <sys/time.h>
#define DEFERRED_STRINGIFY(symbol) #symbol
#define SHOW(symbol) \
@@ -53,11 +54,23 @@ int main(void) {
errs += TimeTest(clock_getres, CLOCK_MONOTONIC,
"clock_getres on monotonic clock failed",
"Monotonic clock resolution");
+ errs += TimeTest(clock_getres, CLOCK_PROCESS_CPUTIME_ID,
+ "clock_getres on process CPU-time clock failed",
+ "Process CPU-time clock resolution");
+ errs += TimeTest(clock_getres, CLOCK_THREAD_CPUTIME_ID,
+ "clock_getres on thread CPU-time clock failed",
+ "Thread CPU-time clock resolution");
errs += TimeTest(clock_gettime, CLOCK_REALTIME,
"clock_gettime on realtime clock failed",
"Realtime clock value");
errs += TimeTest(clock_gettime, CLOCK_MONOTONIC,
"clock_gettime on monotonic clock failed",
"Monotonic clock value");
+ errs += TimeTest(clock_gettime, CLOCK_PROCESS_CPUTIME_ID,
+ "clock_gettime on process CPU-time clock failed",
+ "Process CPU-time clock value");
+ errs += TimeTest(clock_gettime, CLOCK_THREAD_CPUTIME_ID,
+ "clock_gettime on thread CPU-time clock failed",
+ "Thread CPU-time clock value");
return errs;
}
« no previous file with comments | « TOOL_REVISIONS ('k') | tests/clock/clock_irt_test.c » ('j') | tests/clock/clock_test.c » ('J')

Powered by Google App Engine
This is Rietveld 408576698