• Home
  • Raw
  • Download

Lines Matching refs:SWAP

93 #ifndef SWAP
94 # define SWAP(_a, _b) do { t = (_a); (_a) = (_b); (_b) = t; } while(0) macro
306 if(Td[PA[SA[m / 2]]] < Td[PA[SA[m]]]) { SWAP(SA[m], SA[m / 2]); } in ss_heapsort()
310 if((size % 2) == 0) { SWAP(SA[0], SA[m]); ss_fixdown(Td, PA, SA, 0, m); } in ss_heapsort()
327 if(Td[PA[*v1]] > Td[PA[*v2]]) { SWAP(v1, v2); } in ss_median3()
341 if(Td[PA[*v2]] > Td[PA[*v3]]) { SWAP(v2, v3); } in ss_median5()
342 if(Td[PA[*v4]] > Td[PA[*v5]]) { SWAP(v4, v5); } in ss_median5()
343 if(Td[PA[*v2]] > Td[PA[*v4]]) { SWAP(v2, v4); SWAP(v3, v5); } in ss_median5()
344 if(Td[PA[*v1]] > Td[PA[*v3]]) { SWAP(v1, v3); } in ss_median5()
345 if(Td[PA[*v1]] > Td[PA[*v4]]) { SWAP(v1, v4); SWAP(v3, v5); } in ss_median5()
456 SWAP(*first, *a); in ss_mintrosort()
462 if(x == v) { SWAP(*b, *a); ++a; } in ss_mintrosort()
468 if(x == v) { SWAP(*c, *d); --d; } in ss_mintrosort()
472 SWAP(*b, *c); in ss_mintrosort()
474 if(x == v) { SWAP(*b, *a); ++a; } in ss_mintrosort()
477 if(x == v) { SWAP(*c, *d); --d; } in ss_mintrosort()
485 for(e = first, f = b - s; 0 < s; --s, ++e, ++f) { SWAP(*e, *f); } in ss_mintrosort()
487 for(e = b, f = last - s; 0 < s; --s, ++e, ++f) { SWAP(*e, *f); } in ss_mintrosort()
969 if(ISAd[SA[m / 2]] < ISAd[SA[m]]) { SWAP(SA[m], SA[m / 2]); } in tr_heapsort()
973 if((size % 2) == 0) { SWAP(SA[0], SA[m]); tr_fixdown(ISAd, SA, 0, m); } in tr_heapsort()
989 if(ISAd[*v1] > ISAd[*v2]) { SWAP(v1, v2); } in tr_median3()
1003 if(ISAd[*v2] > ISAd[*v3]) { SWAP(v2, v3); } in tr_median5()
1004 if(ISAd[*v4] > ISAd[*v5]) { SWAP(v4, v5); } in tr_median5()
1005 if(ISAd[*v2] > ISAd[*v4]) { SWAP(v2, v4); SWAP(v3, v5); } in tr_median5()
1006 if(ISAd[*v1] > ISAd[*v3]) { SWAP(v1, v3); } in tr_median5()
1007 if(ISAd[*v1] > ISAd[*v4]) { SWAP(v1, v4); SWAP(v3, v5); } in tr_median5()
1080 if(x == v) { SWAP(*b, *a); ++a; } in tr_partition()
1086 if(x == v) { SWAP(*c, *d); --d; } in tr_partition()
1090 SWAP(*b, *c); in tr_partition()
1092 if(x == v) { SWAP(*b, *a); ++a; } in tr_partition()
1095 if(x == v) { SWAP(*c, *d); --d; } in tr_partition()
1102 for(e = first, f = b - s; 0 < s; --s, ++e, ++f) { SWAP(*e, *f); } in tr_partition()
1104 for(e = b, f = last - s; 0 < s; --s, ++e, ++f) { SWAP(*e, *f); } in tr_partition()
1294 SWAP(*first, *a); in tr_introsort()