]> wimlib.net Git - wimlib/blobdiff - src/divsufsort.c
Stop force-inlining everything marked 'inline'
[wimlib] / src / divsufsort.c
index 6753695657b6ed09b36925279f3eb03a6f1b6ee5..c80412f5cad1f9f18478b3e4327b8fd431642d2c 100644 (file)
@@ -111,7 +111,7 @@ static const int lg_table[256]= {
 
 #if (SS_BLOCKSIZE == 0) || (SS_INSERTIONSORT_THRESHOLD < SS_BLOCKSIZE)
 
 
 #if (SS_BLOCKSIZE == 0) || (SS_INSERTIONSORT_THRESHOLD < SS_BLOCKSIZE)
 
-static inline
+static forceinline
 int
 ss_ilg(int n) {
 #if SS_BLOCKSIZE == 0
 int
 ss_ilg(int n) {
 #if SS_BLOCKSIZE == 0
@@ -154,7 +154,7 @@ static const int sqq_table[256] = {
 247, 248, 248, 249, 249, 250, 250, 251, 251, 252, 252, 253, 253, 254, 254, 255
 };
 
 247, 248, 248, 249, 249, 250, 250, 251, 251, 252, 252, 253, 253, 254, 254, 255
 };
 
-static inline
+static forceinline
 int
 ss_isqrt(int x) {
   int y, e;
 int
 ss_isqrt(int x) {
   int y, e;
@@ -187,7 +187,7 @@ ss_isqrt(int x) {
 /*---------------------------------------------------------------------------*/
 
 /* Compares two suffixes. */
 /*---------------------------------------------------------------------------*/
 
 /* Compares two suffixes. */
-static inline
+static forceinline
 int
 ss_compare(const unsigned char *T,
            const int *p1, const int *p2,
 int
 ss_compare(const unsigned char *T,
            const int *p1, const int *p2,
@@ -238,7 +238,7 @@ ss_insertionsort(const unsigned char *T, const int *PA,
 
 #if (SS_BLOCKSIZE == 0) || (SS_INSERTIONSORT_THRESHOLD < SS_BLOCKSIZE)
 
 
 #if (SS_BLOCKSIZE == 0) || (SS_INSERTIONSORT_THRESHOLD < SS_BLOCKSIZE)
 
-static inline
+static forceinline
 void
 ss_fixdown(const unsigned char *Td, const int *PA,
            int *SA, int i, int size) {
 void
 ss_fixdown(const unsigned char *Td, const int *PA,
            int *SA, int i, int size) {
@@ -280,7 +280,7 @@ ss_heapsort(const unsigned char *Td, const int *PA, int *SA, int size) {
 /*---------------------------------------------------------------------------*/
 
 /* Returns the median of three elements. */
 /*---------------------------------------------------------------------------*/
 
 /* Returns the median of three elements. */
-static inline
+static forceinline
 int *
 ss_median3(const unsigned char *Td, const int *PA,
            int *v1, int *v2, int *v3) {
 int *
 ss_median3(const unsigned char *Td, const int *PA,
            int *v1, int *v2, int *v3) {
@@ -293,7 +293,7 @@ ss_median3(const unsigned char *Td, const int *PA,
 }
 
 /* Returns the median of five elements. */
 }
 
 /* Returns the median of five elements. */
-static inline
+static forceinline
 int *
 ss_median5(const unsigned char *Td, const int *PA,
            int *v1, int *v2, int *v3, int *v4, int *v5) {
 int *
 ss_median5(const unsigned char *Td, const int *PA,
            int *v1, int *v2, int *v3, int *v4, int *v5) {
@@ -307,7 +307,7 @@ ss_median5(const unsigned char *Td, const int *PA,
 }
 
 /* Returns the pivot element. */
 }
 
 /* Returns the pivot element. */
-static inline
+static forceinline
 int *
 ss_pivot(const unsigned char *Td, const int *PA, int *first, int *last) {
   int *middle;
 int *
 ss_pivot(const unsigned char *Td, const int *PA, int *first, int *last) {
   int *middle;
@@ -335,7 +335,7 @@ ss_pivot(const unsigned char *Td, const int *PA, int *first, int *last) {
 /*---------------------------------------------------------------------------*/
 
 /* Binary partition for substrings. */
 /*---------------------------------------------------------------------------*/
 
 /* Binary partition for substrings. */
-static inline
+static forceinline
 int *
 ss_partition(const int *PA,
                     int *first, int *last, int depth) {
 int *
 ss_partition(const int *PA,
                     int *first, int *last, int depth) {
@@ -496,7 +496,7 @@ ss_mintrosort(const unsigned char *T, const int *PA,
 
 #if SS_BLOCKSIZE != 0
 
 
 #if SS_BLOCKSIZE != 0
 
-static inline
+static forceinline
 void
 ss_blockswap(int *a, int *b, int n) {
   int t;
 void
 ss_blockswap(int *a, int *b, int n) {
   int t;
@@ -505,7 +505,7 @@ ss_blockswap(int *a, int *b, int n) {
   }
 }
 
   }
 }
 
-static inline
+static forceinline
 void
 ss_rotate(int *first, int *middle, int *last) {
   int *a, *b, t;
 void
 ss_rotate(int *first, int *middle, int *last) {
   int *a, *b, t;
@@ -865,7 +865,7 @@ sssort(const unsigned char *T, const int *PA,
 
 /*---------------------------------------------------------------------------*/
 
 
 /*---------------------------------------------------------------------------*/
 
-static inline
+static forceinline
 int
 tr_ilg(int n) {
   return (n & 0xffff0000) ?
 int
 tr_ilg(int n) {
   return (n & 0xffff0000) ?
@@ -900,7 +900,7 @@ tr_insertionsort(const int *ISAd, int *first, int *last) {
 
 /*---------------------------------------------------------------------------*/
 
 
 /*---------------------------------------------------------------------------*/
 
-static inline
+static forceinline
 void
 tr_fixdown(const int *ISAd, int *SA, int i, int size) {
   int j, k;
 void
 tr_fixdown(const int *ISAd, int *SA, int i, int size) {
   int j, k;
@@ -941,7 +941,7 @@ tr_heapsort(const int *ISAd, int *SA, int size) {
 /*---------------------------------------------------------------------------*/
 
 /* Returns the median of three elements. */
 /*---------------------------------------------------------------------------*/
 
 /* Returns the median of three elements. */
-static inline
+static forceinline
 int *
 tr_median3(const int *ISAd, int *v1, int *v2, int *v3) {
   if(ISAd[*v1] > ISAd[*v2]) { SWAP(v1, v2); }
 int *
 tr_median3(const int *ISAd, int *v1, int *v2, int *v3) {
   if(ISAd[*v1] > ISAd[*v2]) { SWAP(v1, v2); }
@@ -953,7 +953,7 @@ tr_median3(const int *ISAd, int *v1, int *v2, int *v3) {
 }
 
 /* Returns the median of five elements. */
 }
 
 /* Returns the median of five elements. */
-static inline
+static forceinline
 int *
 tr_median5(const int *ISAd,
            int *v1, int *v2, int *v3, int *v4, int *v5) {
 int *
 tr_median5(const int *ISAd,
            int *v1, int *v2, int *v3, int *v4, int *v5) {
@@ -967,7 +967,7 @@ tr_median5(const int *ISAd,
 }
 
 /* Returns the pivot element. */
 }
 
 /* Returns the pivot element. */
-static inline
+static forceinline
 int *
 tr_pivot(const int *ISAd, int *first, int *last) {
   int *middle;
 int *
 tr_pivot(const int *ISAd, int *first, int *last) {
   int *middle;
@@ -1002,14 +1002,14 @@ struct _trbudget_t {
   int count;
 };
 
   int count;
 };
 
-static inline
+static forceinline
 void
 trbudget_init(trbudget_t *budget, int chance, int incval) {
   budget->chance = chance;
   budget->remain = budget->incval = incval;
 }
 
 void
 trbudget_init(trbudget_t *budget, int chance, int incval) {
   budget->chance = chance;
   budget->remain = budget->incval = incval;
 }
 
-static inline
+static forceinline
 int
 trbudget_check(trbudget_t *budget, int size) {
   if(size <= budget->remain) { budget->remain -= size; return 1; }
 int
 trbudget_check(trbudget_t *budget, int size) {
   if(size <= budget->remain) { budget->remain -= size; return 1; }
@@ -1022,7 +1022,7 @@ trbudget_check(trbudget_t *budget, int size) {
 
 /*---------------------------------------------------------------------------*/
 
 
 /*---------------------------------------------------------------------------*/
 
-static inline
+static forceinline
 void
 tr_partition(const int *ISAd,
              int *first, int *middle, int *last,
 void
 tr_partition(const int *ISAd,
              int *first, int *middle, int *last,