summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/cmpdi2.c13
-rw-r--r--lib/ucmpdi2.c13
2 files changed, 26 insertions, 0 deletions
diff --git a/lib/cmpdi2.c b/lib/cmpdi2.c
index c2b1f69f..52634d9c 100644
--- a/lib/cmpdi2.c
+++ b/lib/cmpdi2.c
@@ -36,3 +36,16 @@ __cmpdi2(di_int a, di_int b)
return 2;
return 1;
}
+
+#ifdef __ARM_EABI__
+/* Returns: if (a < b) returns -1
+* if (a == b) returns 0
+* if (a > b) returns 1
+*/
+COMPILER_RT_ABI si_int
+__aeabi_lcmp(di_int a, di_int b)
+{
+ return __cmpdi2(a, b) - 1;
+}
+#endif
+
diff --git a/lib/ucmpdi2.c b/lib/ucmpdi2.c
index 3242bbf0..40af2361 100644
--- a/lib/ucmpdi2.c
+++ b/lib/ucmpdi2.c
@@ -36,3 +36,16 @@ __ucmpdi2(du_int a, du_int b)
return 2;
return 1;
}
+
+#ifdef __ARM_EABI__
+/* Returns: if (a < b) returns -1
+* if (a == b) returns 0
+* if (a > b) returns 1
+*/
+COMPILER_RT_ABI si_int
+__aeabi_ulcmp(di_int a, di_int b)
+{
+ return __ucmpdi2(a, b) - 1;
+}
+#endif
+