-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MINIFICPP-2139 Fix build on ARM7 architecture
Closes #1590 Signed-off-by: Marton Szasz <[email protected]>
- Loading branch information
Showing
3 changed files
with
23 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
diff --git a/utilities/transactions/lock/range/range_tree/lib/portability/toku_time.h b/utilities/transactions/lock/range/range_tree/lib/portability/toku_time.h | ||
index 225e3fa72..cd5f935f1 100644 | ||
--- a/utilities/transactions/lock/range/range_tree/lib/portability/toku_time.h | ||
+++ b/utilities/transactions/lock/range/range_tree/lib/portability/toku_time.h | ||
@@ -131,6 +131,10 @@ static inline tokutime_t toku_time_now(void) { | ||
uint64_t result; | ||
__asm __volatile__("mrs %[rt], cntvct_el0" : [ rt ] "=r"(result)); | ||
return result; | ||
+#elif defined(__arm__) | ||
+ uint32_t lo, hi; | ||
+ __asm __volatile__("mrrc p15, 1, %[lo], %[hi], c14" : [ lo ] "=r" (lo), [hi] "=r" (hi)); | ||
+ return (uint64_t)hi << 32 | lo; | ||
#elif defined(__powerpc__) | ||
return __ppc_get_timebase(); | ||
#elif defined(__s390x__) |