Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
(func $_cdef_filter_block_c (; 407 ;) (; has Stack IR ;) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (param $4 i32) (param $5 i32) (param $6 i32) (param $7 i32) (param $8 i32) (param $9 i32) (param $10 i32)
(local $11 i32)
(local $12 i32)
(local $13 i32)
(local $14 i32)
(local $15 i32)
(local $16 i32)
(local $17 i32)
(local $18 i32)
(local $19 i32)
(local $20 i32)
(local $21 i32)
(local $22 i32)
(local $23 i32)
(local $24 i32)
(local $25 i32)
(local $26 i32)
(local $27 i32)
(local $28 i32)
(local $29 i32)
(local $30 i32)
(local $31 i32)
(local $32 i32)
(local $33 i32)
(local $34 i32)
(local $35 i32)
(local $36 i32)
(local $37 i32)
(local $38 i32)
(local.set $13
(global.get $STACKTOP)
)
(global.set $STACKTOP
(i32.add
(global.get $STACKTOP)
(i32.const 288)
)
)
(local.set $25
(local.get $13)
)
(local.set $22
(if (result i32)
(i32.and
(local.get $10)
(i32.const 4)
)
(i32.const -2)
(if (result i32)
(i32.gt_s
(local.get $4)
(i32.const -4)
)
(block (result i32)
(local.set $11
(i32.add
(local.get $4)
(i32.const 3)
)
)
(local.set $13
(i32.const 0)
)
(loop $while-in
(i32.store16
(i32.add
(i32.shl
(local.get $13)
(i32.const 1)
)
(local.get $25)
)
(i32.const 32767)
)
(local.set $12
(i32.add
(local.get $13)
(i32.const 1)
)
)
(if
(i32.ne
(local.get $11)
(local.get $13)
)
(block
(local.set $13
(local.get $12)
)
(br $while-in)
)
)
)
(local.set $21
(i32.add
(local.get $25)
(i32.const 24)
)
)
(local.set $13
(i32.const 0)
)
(loop $while-in1 (result i32)
(i32.store16
(i32.add
(i32.shl
(local.get $13)
(i32.const 1)
)
(local.get $21)
)
(i32.const 32767)
)
(local.set $12
(i32.add
(local.get $13)
(i32.const 1)
)
)
(if (result i32)
(i32.eq
(local.get $11)
(local.get $13)
)
(i32.const 0)
(block
(local.set $13
(local.get $12)
)
(br $while-in1)
)
)
)
)
(i32.const 0)
)
)
)
(local.set $21
(i32.add
(local.get $25)
(i32.const 52)
)
)
(local.set $13
(i32.add
(local.get $5)
(i32.const 2)
)
)
(if
(i32.eqz
(i32.and
(local.get $10)
(i32.const 8)
)
)
(local.set $13
(if (result i32)
(i32.gt_s
(local.get $4)
(i32.const -4)
)
(block (result i32)
(local.set $11
(i32.add
(i32.add
(i32.shl
(i32.mul
(local.get $5)
(i32.const 12)
)
(i32.const 1)
)
(local.get $21)
)
(i32.const -4)
)
)
(local.set $14
(i32.add
(local.get $4)
(i32.const 3)
)
)
(local.set $13
(i32.const 0)
)
(loop $while-in3
(i32.store16
(i32.add
(i32.shl
(local.get $13)
(i32.const 1)
)
(local.get $11)
)
(i32.const 32767)
)
(local.set $12
(i32.add
(local.get $13)
(i32.const 1)
)
)
(if
(i32.ne
(local.get $13)
(local.get $14)
)
(block
(local.set $13
(local.get $12)
)
(br $while-in3)
)
)
)
(local.set $11
(i32.add
(local.get $11)
(i32.const 24)
)
)
(local.set $13
(i32.const 0)
)
(loop $while-in5 (result i32)
(i32.store16
(i32.add
(i32.shl
(local.get $13)
(i32.const 1)
)
(local.get $11)
)
(i32.const 32767)
)
(local.set $12
(i32.add
(local.get $13)
(i32.const 1)
)
)
(if (result i32)
(i32.eq
(local.get $13)
(local.get $14)
)
(local.get $5)
(block
(local.set $13
(local.get $12)
)
(br $while-in5)
)
)
)
)
(local.get $5)
)
)
)
(local.set $14
(if (result i32)
(i32.and
(local.get $10)
(i32.const 1)
)
(i32.const -2)
(if (result i32)
(i32.gt_s
(local.tee $14
(i32.sub
(local.get $13)
(local.get $22)
)
)
(i32.const 0)
)
(block (result i32)
(local.set $11
(i32.const 0)
)
(local.set $12
(i32.add
(i32.add
(i32.shl
(i32.mul
(local.get $22)
(i32.const 12)
)
(i32.const 1)
)
(local.get $21)
)
(i32.const -4)
)
)
(loop $while-in7 (result i32)
(i32.store16
(local.get $12)
(i32.const 32767)
)
(i32.store16 offset=2
(local.get $12)
(i32.const 32767)
)
(local.set $12
(i32.add
(local.get $12)
(i32.const 24)
)
)
(br_if $while-in7
(i32.ne
(local.tee $11
(i32.add
(local.get $11)
(i32.const 1)
)
)
(local.get $14)
)
)
(i32.const 0)
)
)
(i32.const 0)
)
)
)
(local.set $12
(i32.add
(local.get $4)
(i32.const 2)
)
)
(if
(i32.and
(i32.lt_s
(local.get $22)
(i32.const 0)
)
(i32.lt_s
(local.get $14)
(local.tee $10
(if (result i32)
(i32.and
(local.get $10)
(i32.const 2)
)
(local.get $12)
(if (result i32)
(i32.gt_s
(local.tee $11
(i32.sub
(local.get $13)
(local.get $22)
)
)
(i32.const 0)
)
(block (result i32)
(local.set $12
(i32.const 0)
)
(local.set $10
(i32.add
(i32.add
(i32.shl
(i32.mul
(local.get $22)
(i32.const 12)
)
(i32.const 1)
)
(local.get $21)
)
(i32.shl
(local.get $4)
(i32.const 1)
)
)
)
(loop $while-in9 (result i32)
(i32.store16
(local.get $10)
(i32.const 32767)
)
(i32.store16 offset=2
(local.get $10)
(i32.const 32767)
)
(local.set $10
(i32.add
(local.get $10)
(i32.const 24)
)
)
(br_if $while-in9
(i32.ne
(local.tee $12
(i32.add
(local.get $12)
(i32.const 1)
)
)
(local.get $11)
)
)
(local.get $4)
)
)
(local.get $4)
)
)
)
)
)
(block
(local.set $12
(local.get $22)
)
(loop $while-in11
(local.set $22
(i32.mul
(local.get $12)
(i32.const 12)
)
)
(local.set $17
(i32.load
(i32.add
(i32.shl
(i32.and
(local.get $12)
(i32.const 1)
)
(i32.const 2)
)
(local.get $3)
)
)
)
(local.set $11
(local.get $14)
)
(loop $while-in13
(i32.store16
(i32.add
(i32.shl
(i32.add
(local.get $11)
(local.get $22)
)
(i32.const 1)
)
(local.get $21)
)
(i32.load8_u
(i32.add
(local.get $11)
(local.get $17)
)
)
)
(br_if $while-in13
(i32.ne
(local.tee $11
(i32.add
(local.get $11)
(i32.const 1)
)
)
(local.get $10)
)
)
)
(local.set $11
(i32.add
(local.get $12)
(i32.const 1)
)
)
(if
(i32.lt_s
(local.get $12)
(i32.const -1)
)
(block
(local.set $12
(local.get $11)
)
(br $while-in11)
)
)
)
)
)
(if
(i32.and
(local.tee $22
(i32.gt_s
(local.get $5)
(i32.const 0)
)
)
(i32.lt_s
(local.get $14)
(i32.const 0)
)
)
(block
(local.set $12
(i32.const 0)
)
(loop $while-in15
(local.set $17
(i32.mul
(local.get $12)
(i32.const 12)
)
)
(local.set $3
(local.get $14)
)
(loop $while-in17
(i32.store16
(i32.add
(i32.shl
(i32.add
(local.get $3)
(local.get $17)
)
(i32.const 1)
)
(local.get $21)
)
(i32.load8_u
(i32.add
(i32.add
(local.get $3)
(i32.const 2)
)
(i32.add
(i32.shl
(local.get $12)
(i32.const 1)
)
(local.get $2)
)
)
)
)
(local.set $11
(i32.add
(local.get $3)
(i32.const 1)
)
)
(if
(i32.lt_s
(local.get $3)
(i32.const -1)
)
(block
(local.set $3
(local.get $11)
)
(br $while-in17)
)
)
)
(br_if $while-in15
(i32.ne
(local.tee $12
(i32.add
(local.get $12)
(i32.const 1)
)
)
(local.get $5)
)
)
)
)
)
(if
(i32.gt_s
(local.get $13)
(i32.const 0)
)
(block
(local.set $3
(local.get $21)
)
(local.set $12
(local.get $0)
)
(local.set $11
(i32.const 0)
)
(loop $while-in19
(if
(i32.lt_s
(local.tee $2
(select
(i32.const 0)
(local.get $14)
(i32.lt_s
(local.get $11)
(local.get $5)
)
)
)
(local.get $10)
)
(loop $while-in21
(i32.store16
(i32.add
(i32.shl
(local.get $2)
(i32.const 1)
)
(local.get $3)
)
(i32.load8_u
(i32.add
(local.get $2)
(local.get $12)
)
)
)
(br_if $while-in21
(i32.ne
(local.tee $2
(i32.add
(local.get $2)
(i32.const 1)
)
)
(local.get $10)
)
)
)
)
(local.set $12
(i32.add
(local.get $1)
(local.get $12)
)
)
(local.set $3
(i32.add
(local.get $3)
(i32.const 24)
)
)
(br_if $while-in19
(i32.ne
(local.tee $11
(i32.add
(local.get $11)
(i32.const 1)
)
)
(local.get $13)
)
)
)
)
)
(if
(i32.eqz
(local.get $22)
)
(block
(global.set $STACKTOP
(local.get $25)
)
(return)
)
)
(local.set $22
(i32.sub
(i32.const 4)
(i32.and
(local.get $6)
(i32.const 1)
)
)
)
(local.set $33
(i32.gt_s
(local.get $4)
(i32.const 0)
)
)
(local.set $34
(i32.eqz
(local.get $6)
)
)
(local.set $35
(i32.and
(i32.add
(local.get $8)
(i32.const 2)
)
(i32.const 7)
)
)
(local.set $36
(i32.and
(i32.add
(local.get $8)
(i32.const 6)
)
(i32.const 7)
)
)
(local.set $37
(i32.eqz
(local.get $7)
)
)
(local.set $30
(select
(local.tee $3
(i32.add
(local.tee $2
(i32.add
(local.get $9)
(i32.const -31)
)
)
(i32.clz
(local.get $6)
)
)
)
(i32.const 0)
(i32.gt_s
(local.get $3)
(i32.const 0)
)
)
)
(local.set $26
(select
(local.tee $2
(i32.add
(local.get $2)
(i32.clz
(local.get $7)
)
)
)
(i32.const 0)
(i32.gt_s
(local.get $2)
(i32.const 0)
)
)
)
(local.set $2
(local.get $21)
)
(local.set $21
(i32.const 0)
)
(local.set $3
(local.get $0)
)
(loop $while-in23
(if
(local.get $33)
(block
(local.set $13
(i32.const 0)
)
(loop $while-in25
(local.set $9
(i32.const 0)
)
(local.set $11
(local.tee $14
(i32.load8_u
(local.tee $38
(i32.add
(local.get $3)
(local.get $13)
)
)
)
)
)
(local.set $10
(local.get $14)
)
(local.set $0
(local.get $22)
)
(local.set $12
(i32.const 0)
)
(loop $while-in27
(local.set $17
(i32.and
(local.tee $27
(i32.load16_s
(i32.add
(i32.shl
(i32.add
(local.get $13)
(local.tee $20
(i32.load8_s
(i32.add
(local.get $12)
(i32.add
(i32.shl
(local.get $8)
(i32.const 1)
)
(i32.const 100992)
)
)
)
)
)
(i32.const 1)
)
(local.get $2)
)
)
)
(i32.const 65535)
)
)
(local.set $20
(i32.and
(local.tee $28
(i32.load16_s
(i32.add
(i32.shl
(i32.sub
(local.get $13)
(local.get $20)
)
(i32.const 1)
)
(local.get $2)
)
)
)
(i32.const 65535)
)
)
(local.set $16
(i32.sub
(local.get $17)
(local.get $14)
)
)
(local.set $9
(i32.add
(i32.mul
(if (result i32)
(local.get $34)
(i32.const 0)
(block (result i32)
(local.set $19
(select
(local.tee $15
(i32.sub
(local.get $6)
(i32.shr_s
(local.tee $18
(select
(local.get $16)
(i32.sub
(i32.const 0)
(local.get $16)
)
(i32.gt_s
(local.get $16)
(i32.const -1)
)
)
)
(local.get $30)
)
)
)
(i32.const 0)
(i32.gt_s
(local.get $15)
(i32.const 0)
)
)
)
(local.set $24
(select
(local.tee $24
(i32.sub
(local.get $6)
(i32.shr_s
(local.tee $23
(select
(local.tee $15
(i32.sub
(local.get $20)
(local.get $14)
)
)
(i32.sub
(i32.const 0)
(local.get $15)
)
(i32.gt_s
(local.get $15)
(i32.const -1)
)
)
)
(local.get $30)
)
)
)
(i32.const 0)
(i32.gt_s
(local.get $24)
(i32.const 0)
)
)
)
(local.set $9
(i32.add
(local.get $9)
(i32.mul
(local.get $0)
(select
(i32.sub
(i32.const 0)
(local.tee $9
(select
(local.get $18)
(local.get $19)
(i32.lt_s
(local.get $18)
(local.get $19)
)
)
)
)
(local.get $9)
(i32.lt_s
(local.get $16)
(i32.const 0)
)
)
)
)
)
(select
(i32.sub
(i32.const 0)
(local.tee $23
(select
(local.get $23)
(local.get $24)
(i32.lt_s
(local.get $23)
(local.get $24)
)
)
)
)
(local.get $23)
(i32.lt_s
(local.get $15)
(i32.const 0)
)
)
)
)
(local.get $0)
)
(local.get $9)
)
)
(local.set $11
(select
(local.tee $11
(select
(local.tee $11
(select
(local.tee $11
(select
(local.tee $11
(select
(local.tee $11
(select
(local.get $11)
(select
(local.get $17)
(local.get $11)
(i32.lt_s
(local.get $11)
(local.get $17)
)
)
(i32.eq
(local.get $27)
(i32.const 32767)
)
)
)
(select
(local.get $20)
(local.get $11)
(i32.lt_s
(local.get $11)
(local.get $20)
)
)
(i32.eq
(local.get $28)
(i32.const 32767)
)
)
)
(select
(local.tee $16
(i32.and
(local.tee $18
(i32.load16_s
(i32.add
(i32.shl
(i32.add
(local.get $13)
(local.tee $15
(i32.load8_s
(i32.add
(local.get $12)
(i32.add
(i32.shl
(local.get $35)
(i32.const 1)
)
(i32.const 100992)
)
)
)
)
)
(i32.const 1)
)
(local.get $2)
)
)
)
(i32.const 65535)
)
)
(local.get $11)
(i32.lt_s
(local.get $11)
(local.get $16)
)
)
(i32.eq
(local.get $18)
(i32.const 32767)
)
)
)
(select
(local.tee $15
(i32.and
(local.tee $18
(i32.load16_s
(i32.add
(i32.shl
(i32.sub
(local.get $13)
(local.get $15)
)
(i32.const 1)
)
(local.get $2)
)
)
)
(i32.const 65535)
)
)
(local.get $11)
(i32.lt_s
(local.get $11)
(local.get $15)
)
)
(i32.eq
(local.get $18)
(i32.const 32767)
)
)
)
(select
(local.tee $18
(i32.and
(local.tee $23
(i32.load16_s
(i32.add
(i32.shl
(i32.add
(local.get $13)
(local.tee $19
(i32.load8_s
(i32.add
(local.get $12)
(i32.add
(i32.shl
(local.get $36)
(i32.const 1)
)
(i32.const 100992)
)
)
)
)
)
(i32.const 1)
)
(local.get $2)
)
)
)
(i32.const 65535)
)
)
(local.get $11)
(i32.lt_s
(local.get $11)
(local.get $18)
)
)
(i32.eq
(local.get $23)
(i32.const 32767)
)
)
)
(select
(local.tee $19
(i32.and
(local.tee $23
(i32.load16_s
(i32.add
(i32.shl
(i32.sub
(local.get $13)
(local.get $19)
)
(i32.const 1)
)
(local.get $2)
)
)
)
(i32.const 65535)
)
)
(local.get $11)
(i32.lt_s
(local.get $11)
(local.get $19)
)
)
(i32.eq
(local.get $23)
(i32.const 32767)
)
)
)
(local.set $10
(select
(local.get $19)
(local.tee $10
(select
(local.get $18)
(local.tee $10
(select
(local.get $15)
(local.tee $10
(select
(local.get $16)
(local.tee $10
(select
(local.get $20)
(local.tee $10
(select
(local.get $17)
(local.get $10)
(i32.gt_s
(local.get $10)
(local.get $17)
)
)
)
(i32.gt_s
(local.get $10)
(local.get $20)
)
)
)
(i32.gt_s
(local.get $10)
(local.get $16)
)
)
)
(i32.gt_s
(local.get $10)
(local.get $15)
)
)
)
(i32.gt_s
(local.get $10)
(local.get $18)
)
)
)
(i32.gt_s
(local.get $10)
(local.get $19)
)
)
)
(local.set $23
(i32.sub
(i32.const 2)
(local.get $12)
)
)
(local.set $17
(i32.sub
(local.get $16)
(local.get $14)
)
)
(local.set $0
(i32.add
(i32.add
(local.get $0)
(i32.const 6)
)
(i32.mul
(local.get $0)
(i32.const -2)
)
)
)
(local.set $9
(i32.add
(i32.mul
(if (result i32)
(local.get $37)
(i32.const 0)
(block (result i32)
(local.set $27
(select
(local.tee $20
(i32.sub
(local.get $7)
(i32.shr_s
(local.tee $24
(select
(local.get $17)
(i32.sub
(i32.const 0)
(local.get $17)
)
(i32.gt_s
(local.get $17)
(i32.const -1)
)
)
)
(local.get $26)
)
)
)
(i32.const 0)
(i32.gt_s
(local.get $20)
(i32.const 0)
)
)
)
(local.set $31
(select
(local.tee $16
(i32.sub
(local.get $7)
(i32.shr_s
(local.tee $28
(select
(local.tee $20
(i32.sub
(local.get $15)
(local.get $14)
)
)
(i32.sub
(i32.const 0)
(local.get $20)
)
(i32.gt_s
(local.get $20)
(i32.const -1)
)
)
)
(local.get $26)
)
)
)
(i32.const 0)
(i32.gt_s
(local.get $16)
(i32.const 0)
)
)
)
(local.set $32
(select
(local.tee $15
(i32.sub
(local.get $7)
(i32.shr_s
(local.tee $18
(select
(local.tee $16
(i32.sub
(local.get $18)
(local.get $14)
)
)
(i32.sub
(i32.const 0)
(local.get $16)
)
(i32.gt_s
(local.get $16)
(i32.const -1)
)
)
)
(local.get $26)
)
)
)
(i32.const 0)
(i32.gt_s
(local.get $15)
(i32.const 0)
)
)
)
(local.set $29
(select
(local.tee $29
(i32.sub
(local.get $7)
(i32.shr_s
(local.tee $19
(select
(local.tee $15
(i32.sub
(local.get $19)
(local.get $14)
)
)
(i32.sub
(i32.const 0)
(local.get $15)
)
(i32.gt_s
(local.get $15)
(i32.const -1)
)
)
)
(local.get $26)
)
)
)
(i32.const 0)
(i32.gt_s
(local.get $29)
(i32.const 0)
)
)
)
(local.set $9
(i32.add
(local.get $9)
(i32.mul
(local.get $23)
(i32.add
(select
(i32.sub
(i32.const 0)
(local.tee $9
(select
(local.get $18)
(local.get $32)
(i32.lt_s
(local.get $18)
(local.get $32)
)
)
)
)
(local.get $9)
(i32.lt_s
(local.get $16)
(i32.const 0)
)
)
(i32.add
(select
(i32.sub
(i32.const 0)
(local.tee $9
(select
(local.get $24)
(local.get $27)
(i32.lt_s
(local.get $24)
(local.get $27)
)
)
)
)
(local.get $9)
(i32.lt_s
(local.get $17)
(i32.const 0)
)
)
(select
(i32.sub
(i32.const 0)
(local.tee $9
(select
(local.get $28)
(local.get $31)
(i32.lt_s
(local.get $28)
(local.get $31)
)
)
)
)
(local.get $9)
(i32.lt_s
(local.get $20)
(i32.const 0)
)
)
)
)
)
)
)
(select
(i32.sub
(i32.const 0)
(local.tee $19
(select
(local.get $19)
(local.get $29)
(i32.lt_s
(local.get $19)
(local.get $29)
)
)
)
)
(local.get $19)
(i32.lt_s
(local.get $15)
(i32.const 0)
)
)
)
)
(local.get $23)
)
(local.get $9)
)
)
(br_if $while-in27
(i32.ne
(local.tee $12
(i32.add
(local.get $12)
(i32.const 1)
)
)
(i32.const 2)
)
)
)
(i32.store8
(local.get $38)
(select
(local.get $10)
(select
(local.get $11)
(local.tee $0
(i32.add
(local.get $14)
(i32.shr_s
(i32.add
(i32.add
(local.get $9)
(i32.const 8)
)
(i32.shr_s
(local.get $9)
(i32.const 31)
)
)
(i32.const 4)
)
)
)
(i32.gt_s
(local.get $0)
(local.get $11)
)
)
(i32.lt_s
(local.get $0)
(local.get $10)
)
)
)
(br_if $while-in25
(i32.ne
(local.tee $13
(i32.add
(local.get $13)
(i32.const 1)
)
)
(local.get $4)
)
)
)
)
)
(local.set $3
(i32.add
(local.get $1)
(local.get $3)
)
)
(local.set $2
(i32.add
(local.get $2)
(i32.const 24)
)
)
(br_if $while-in23
(i32.ne
(local.tee $21
(i32.add
(local.get $21)
(i32.const 1)
)
)
(local.get $5)
)
)
)
(global.set $STACKTOP
(local.get $25)
)
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.