aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarat Dukhan <maratek@google.com>2022-08-23 07:54:10 -0700
committerXNNPACK Team <xnnpack-github-robot@google.com>2022-08-23 07:55:10 -0700
commit6b270bfa436d40570f7768f46896b82729ae0f66 (patch)
tree73e80f02cf92ca9b8d378c64231373c14a211bba
parent3c3769df8dc93069b1464d6912aefa042059503a (diff)
downloadXNNPACK-6b270bfa436d40570f7768f46896b82729ae0f66.tar.gz
Group math_doz_u32 with other u32 math functions
PiperOrigin-RevId: 469458267
-rw-r--r--src/xnnpack/math.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/xnnpack/math.h b/src/xnnpack/math.h
index 3035c74a2..616aef2a9 100644
--- a/src/xnnpack/math.h
+++ b/src/xnnpack/math.h
@@ -43,10 +43,6 @@ XNN_INLINE static size_t doz(size_t a, size_t b) {
return XNN_UNPREDICTABLE(b < a) ? a - b : 0;
}
-XNN_INLINE static uint32_t math_doz_u32(uint32_t a, uint32_t b) {
- return XNN_UNPREDICTABLE(b < a) ? a - b : 0;
-}
-
XNN_INLINE static size_t divide_round_up(size_t n, size_t q) {
return XNN_UNPREDICTABLE(n % q == 0) ? n / q : n / q + 1;
}
@@ -129,6 +125,10 @@ XNN_INLINE static uint32_t math_max_u32(uint32_t a, uint32_t b) {
return XNN_UNPREDICTABLE(a > b) ? a : b;
}
+XNN_INLINE static uint32_t math_doz_u32(uint32_t a, uint32_t b) {
+ return XNN_UNPREDICTABLE(a > b) ? a - b : 0;
+}
+
XNN_INLINE static int64_t math_mulext_s32(int32_t a, int32_t b) {
#if defined(_MSC_VER) && defined(_M_IX86)
return (int64_t) __emul((int) a, (int) b);