add code for x86
authorMazet Laurent <laurent.mazet@thalesgroup.com>
Fri, 17 Oct 2025 14:08:37 +0000 (16:08 +0200)
committerMazet Laurent <laurent.mazet@thalesgroup.com>
Fri, 17 Oct 2025 14:08:37 +0000 (16:08 +0200)
load.c

diff --git a/load.c b/load.c
index b1062f1f269d000c62d9adedd4e0706a6251a4b7..5ec043a74d100fcb44c6a787886aa5df8b652d48 100644 (file)
--- a/load.c
+++ b/load.c
@@ -185,6 +185,9 @@ double estimate_tics_clock (void)
 
 double estimate_cpu_clock (void)
 {
+#ifndef __arm__
+    return estimate_tics_clock ();
+#else
     struct timeval tv1;
     gettimeofday (&tv1, NULL);
 
@@ -220,6 +223,7 @@ double estimate_cpu_clock (void)
         ((double)tv1.tv_sec + tv1.tv_usec * 1e-6);
 
     return instructions / runtime;
+#endif /* __arm__ */
 }
 
 /* main function */