MCPcopy Create free account
hub / github.com/sql-js/sql.js / _binCollFunc

Function _binCollFunc

js/sql-debug.js:327115–327184  ·  view source on GitHub ↗
($0,$1,$2,$3,$4)

Source from the content-addressed store, hash-verified

327113 STACKTOP = sp;return ($$095|0);
327114}
327115function _binCollFunc($0,$1,$2,$3,$4) {
327116 $0 = $0|0;
327117 $1 = $1|0;
327118 $2 = $2|0;
327119 $3 = $3|0;
327120 $4 = $4|0;
327121 var $$0 = 0, $$0$i = 0, $$0$i22 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, $21 = 0, $22 = 0, $23 = 0, $24 = 0, $25 = 0, $26 = 0;
327122 var $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, label = 0, sp = 0;
327123 sp = STACKTOP;
327124 $5 = ($1|0)<($3|0);
327125 $6 = $5 ? $1 : $3;
327126 $7 = (_memcmp($2,$4,$6)|0);
327127 $8 = ($7|0)==(0);
327128 if (!($8)) {
327129 $$0 = $7;
327130 return ($$0|0);
327131 }
327132 $9 = ($0|0)==(0|0);
327133 L4: do {
327134 if (!($9)) {
327135 $10 = (($2) + ($6)|0);
327136 $11 = (($1) - ($6))|0;
327137 $$0$i = $11;
327138 while(1) {
327139 $12 = ($$0$i|0)>(0);
327140 if (!($12)) {
327141 break;
327142 }
327143 $13 = (($$0$i) + -1)|0;
327144 $14 = (($10) + ($13)|0);
327145 $15 = HEAP8[$14>>0]|0;
327146 $16 = ($15<<24>>24)==(32);
327147 if ($16) {
327148 $$0$i = $13;
327149 } else {
327150 break L4;
327151 }
327152 }
327153 $17 = ($$0$i|0)==(0);
327154 if ($17) {
327155 $18 = (($4) + ($6)|0);
327156 $19 = (($3) - ($6))|0;
327157 $$0$i22 = $19;
327158 while(1) {
327159 $20 = ($$0$i22|0)>(0);
327160 if (!($20)) {
327161 break;
327162 }
327163 $21 = (($$0$i22) + -1)|0;
327164 $22 = (($18) + ($21)|0);
327165 $23 = HEAP8[$22>>0]|0;
327166 $24 = ($23<<24>>24)==(32);
327167 if ($24) {
327168 $$0$i22 = $21;
327169 } else {
327170 break L4;
327171 }
327172 }

Callers

nothing calls this directly

Calls 1

_memcmpFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…