Skip to content

Instantly share code, notes, and snippets.

@chfast
Last active August 16, 2019 17:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chfast/df2c0faf527efcf7b43465f6e739111a to your computer and use it in GitHub Desktop.
Save chfast/df2c0faf527efcf7b43465f6e739111a to your computer and use it in GitHub Desktop.
Keccak.wasm
(module
(type (;0;) (func (param i32)))
(type (;1;) (func (param i32 i32 i32) (result i32)))
(type (;2;) (func (param i32 i32 i32)))
(import "env" "memory" (memory (;0;) 256 256))
(func (;0;) (type 0) (param i32)
(local i32 i32 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64)
local.get 0
i64.load
local.set 20
local.get 0
i64.load offset=8
local.set 21
local.get 0
i64.load offset=16
local.set 37
local.get 0
i64.load offset=24
local.set 22
local.get 0
i64.load offset=32
local.set 23
local.get 0
i64.load offset=40
local.set 24
local.get 0
i64.load offset=48
local.set 11
local.get 0
i64.load offset=56
local.set 25
local.get 0
i32.const -64
i32.sub
local.tee 2
i64.load
local.set 26
local.get 0
i64.load offset=72
local.set 14
local.get 0
i64.load offset=80
local.set 15
local.get 0
i64.load offset=88
local.set 27
local.get 0
i64.load offset=96
local.set 8
local.get 0
i64.load offset=104
local.set 16
local.get 0
i64.load offset=112
local.set 17
local.get 0
i64.load offset=120
local.set 32
local.get 0
i64.load offset=128
local.set 19
local.get 0
i64.load offset=136
local.set 12
local.get 0
i64.load offset=144
local.set 10
local.get 0
i64.load offset=152
local.set 4
local.get 0
i64.load offset=160
local.set 9
local.get 0
i64.load offset=168
local.set 33
local.get 0
i64.load offset=176
local.set 6
local.get 0
i64.load offset=184
local.set 5
local.get 0
i64.load offset=192
local.set 3
loop ;; label = @1
local.get 23
local.get 14
local.get 17
local.get 3
local.get 4
i64.xor
i64.xor
i64.xor
i64.xor
local.tee 35
local.get 21
local.get 11
local.get 27
local.get 19
local.get 33
i64.xor
i64.xor
i64.xor
i64.xor
local.tee 34
i64.const 1
i64.shl
local.get 34
i64.const 63
i64.shr_u
i64.or
i64.xor
local.set 36
local.get 1
i32.const 3
i32.shl
i32.const 1024
i32.add
i64.load
local.get 20
local.get 36
i64.xor
local.tee 39
local.get 11
local.get 20
local.get 24
local.get 15
local.get 9
local.get 32
i64.xor
i64.xor
i64.xor
i64.xor
local.tee 13
local.get 37
local.get 25
local.get 8
local.get 6
local.get 12
i64.xor
i64.xor
i64.xor
i64.xor
local.tee 7
i64.const 1
i64.shl
local.get 7
i64.const 63
i64.shr_u
i64.or
i64.xor
local.tee 38
i64.xor
local.tee 11
i64.const 44
i64.shl
local.get 11
i64.const 20
i64.shr_u
i64.or
local.tee 28
i64.const -1
i64.xor
local.get 8
local.get 22
local.get 26
local.get 16
local.get 5
local.get 10
i64.xor
i64.xor
i64.xor
i64.xor
local.tee 11
i64.const 1
i64.shl
local.get 11
i64.const 63
i64.shr_u
i64.or
local.get 34
i64.xor
local.tee 18
i64.xor
local.tee 8
i64.const 43
i64.shl
local.get 8
i64.const 21
i64.shr_u
i64.or
local.tee 8
i64.and
i64.xor
i64.xor
local.set 40
local.get 10
local.get 35
i64.const 1
i64.shl
local.get 35
i64.const 63
i64.shr_u
i64.or
local.get 7
i64.xor
local.tee 7
i64.xor
local.tee 10
i64.const 21
i64.shl
local.get 10
i64.const 43
i64.shr_u
i64.or
local.tee 41
local.get 8
i64.const -1
i64.xor
i64.and
local.get 28
i64.xor
local.set 42
local.get 3
local.get 13
i64.const 1
i64.shl
local.get 13
i64.const 63
i64.shr_u
i64.or
local.get 11
i64.xor
local.tee 13
i64.xor
local.tee 3
i64.const 14
i64.shl
local.get 3
i64.const 50
i64.shr_u
i64.or
local.tee 43
local.get 41
i64.const -1
i64.xor
i64.and
local.get 8
i64.xor
local.set 44
local.get 13
local.get 14
i64.xor
local.tee 3
i64.const 20
i64.shl
local.get 3
i64.const 44
i64.shr_u
i64.or
local.tee 14
i64.const -1
i64.xor
local.get 15
local.get 36
i64.xor
local.tee 3
i64.const 3
i64.shl
local.get 3
i64.const 61
i64.shr_u
i64.or
local.tee 10
i64.and
local.get 7
local.get 22
i64.xor
local.tee 3
i64.const 28
i64.shl
local.get 3
i64.const 36
i64.shr_u
i64.or
local.tee 45
i64.xor
local.set 46
local.get 19
local.get 38
i64.xor
local.tee 3
i64.const 45
i64.shl
local.get 3
i64.const 19
i64.shr_u
i64.or
local.tee 47
local.get 10
i64.const -1
i64.xor
i64.and
local.get 14
i64.xor
local.set 29
local.get 6
local.get 18
i64.xor
local.tee 3
i64.const 61
i64.shl
local.get 3
i64.const 3
i64.shr_u
i64.or
local.tee 30
local.get 47
i64.const -1
i64.xor
i64.and
local.get 10
i64.xor
local.set 48
local.get 18
local.get 25
i64.xor
local.tee 3
i64.const 6
i64.shl
local.get 3
i64.const 58
i64.shr_u
i64.or
local.tee 15
i64.const -1
i64.xor
local.get 7
local.get 16
i64.xor
local.tee 3
i64.const 25
i64.shl
local.get 3
i64.const 39
i64.shr_u
i64.or
local.tee 6
i64.and
local.get 21
local.get 38
i64.xor
local.tee 3
i64.const 1
i64.shl
local.get 3
i64.const 63
i64.shr_u
i64.or
local.tee 31
i64.xor
local.set 49
local.get 4
local.get 13
i64.xor
local.tee 3
i64.const 8
i64.shl
local.get 3
i64.const 56
i64.shr_u
i64.or
local.tee 20
local.get 6
i64.const -1
i64.xor
i64.and
local.get 15
i64.xor
local.set 50
local.get 9
local.get 36
i64.xor
local.tee 3
i64.const 18
i64.shl
local.get 3
i64.const 46
i64.shr_u
i64.or
local.tee 21
local.get 20
i64.const -1
i64.xor
i64.and
local.get 6
i64.xor
local.set 22
local.get 24
local.get 36
i64.xor
local.tee 3
i64.const 36
i64.shl
local.get 3
i64.const 28
i64.shr_u
i64.or
local.tee 10
i64.const -1
i64.xor
local.get 27
local.get 38
i64.xor
local.tee 3
i64.const 10
i64.shl
local.get 3
i64.const 54
i64.shr_u
i64.or
local.tee 6
i64.and
local.get 13
local.get 23
i64.xor
local.tee 3
i64.const 27
i64.shl
local.get 3
i64.const 37
i64.shr_u
i64.or
local.tee 23
i64.xor
local.set 51
local.get 12
local.get 18
i64.xor
local.tee 3
i64.const 15
i64.shl
local.get 3
i64.const 49
i64.shr_u
i64.or
local.tee 24
local.get 6
i64.const -1
i64.xor
i64.and
local.get 10
i64.xor
local.set 11
local.get 5
local.get 7
i64.xor
local.tee 3
i64.const 56
i64.shl
local.get 3
i64.const 8
i64.shr_u
i64.or
local.tee 8
local.get 24
i64.const -1
i64.xor
i64.and
local.get 6
i64.xor
local.set 34
local.get 7
local.get 26
i64.xor
local.tee 3
i64.const 55
i64.shl
local.get 3
i64.const 9
i64.shr_u
i64.or
local.tee 4
i64.const -1
i64.xor
local.get 13
local.get 17
i64.xor
local.tee 3
i64.const 39
i64.shl
local.get 3
i64.const 25
i64.shr_u
i64.or
local.tee 9
i64.and
local.get 18
local.get 37
i64.xor
local.tee 3
i64.const 62
i64.shl
local.get 3
i64.const 2
i64.shr_u
i64.or
local.tee 16
i64.xor
local.set 7
local.get 32
local.get 36
i64.xor
local.tee 3
i64.const 41
i64.shl
local.get 3
i64.const 23
i64.shr_u
i64.or
local.tee 6
local.get 9
i64.const -1
i64.xor
i64.and
local.get 4
i64.xor
local.set 35
local.get 33
local.get 38
i64.xor
local.tee 3
i64.const 2
i64.shl
local.get 3
i64.const 62
i64.shr_u
i64.or
local.tee 5
local.get 6
i64.const -1
i64.xor
i64.and
local.get 9
i64.xor
local.set 25
local.get 23
i64.const -1
i64.xor
local.get 10
i64.and
local.get 8
i64.xor
local.tee 32
local.get 45
i64.const -1
i64.xor
local.get 14
i64.and
local.get 30
i64.xor
local.tee 19
local.get 39
i64.const -1
i64.xor
local.get 28
i64.and
local.get 43
i64.xor
local.tee 10
local.get 31
i64.const -1
i64.xor
local.get 15
i64.and
local.get 21
i64.xor
local.tee 13
local.get 16
i64.const -1
i64.xor
local.get 4
i64.and
local.get 5
i64.xor
local.tee 12
i64.xor
i64.xor
i64.xor
i64.xor
local.tee 26
local.get 35
local.get 50
local.get 11
local.get 42
i64.xor
local.get 29
i64.xor
i64.xor
i64.xor
local.tee 17
i64.const 1
i64.shl
local.get 17
i64.const 63
i64.shr_u
i64.or
i64.xor
local.set 18
local.get 7
local.get 49
local.get 51
i64.xor
local.get 46
i64.xor
i64.xor
local.get 40
i64.xor
local.tee 15
local.get 22
local.get 25
local.get 34
local.get 48
i64.xor
i64.xor
local.get 44
i64.xor
i64.xor
local.tee 14
i64.const 1
i64.shl
local.get 14
i64.const 63
i64.shr_u
i64.or
i64.xor
local.tee 28
local.get 29
i64.xor
local.tee 3
i64.const 44
i64.shl
local.get 3
i64.const 20
i64.shr_u
i64.or
local.tee 27
i64.const -1
i64.xor
local.get 22
local.get 8
i64.const -1
i64.xor
local.get 23
i64.and
local.get 24
i64.xor
local.tee 4
local.get 21
i64.const -1
i64.xor
local.get 31
i64.and
local.get 20
i64.xor
local.tee 9
local.get 5
i64.const -1
i64.xor
local.get 16
i64.and
local.get 6
i64.xor
local.tee 33
local.get 30
i64.const -1
i64.xor
local.get 45
i64.and
local.get 47
i64.xor
local.tee 6
i64.xor
i64.xor
local.get 43
i64.const -1
i64.xor
local.get 39
i64.and
local.get 41
i64.xor
local.tee 5
i64.xor
i64.xor
local.tee 8
i64.const 1
i64.shl
local.get 8
i64.const 63
i64.shr_u
i64.or
local.get 17
i64.xor
local.tee 29
i64.xor
local.tee 3
i64.const 43
i64.shl
local.get 3
i64.const 21
i64.shr_u
i64.or
local.tee 16
i64.and
local.get 18
local.get 40
i64.xor
local.tee 17
local.get 1
i32.const 1
i32.or
i32.const 3
i32.shl
i32.const 1024
i32.add
i64.load
i64.xor
i64.xor
local.set 20
local.get 4
local.get 26
i64.const 1
i64.shl
local.get 26
i64.const 63
i64.shr_u
i64.or
local.get 14
i64.xor
local.tee 30
i64.xor
local.tee 3
i64.const 21
i64.shl
local.get 3
i64.const 43
i64.shr_u
i64.or
local.tee 4
local.get 16
i64.const -1
i64.xor
i64.and
local.get 27
i64.xor
local.set 21
local.get 12
local.get 15
i64.const 1
i64.shl
local.get 15
i64.const 63
i64.shr_u
i64.or
local.get 8
i64.xor
local.tee 31
i64.xor
local.tee 3
i64.const 14
i64.shl
local.get 3
i64.const 50
i64.shr_u
i64.or
local.tee 3
local.get 4
i64.const -1
i64.xor
i64.and
local.get 16
i64.xor
local.set 37
local.get 3
i64.const -1
i64.xor
local.get 17
i64.and
local.get 4
i64.xor
local.set 22
local.get 17
i64.const -1
i64.xor
local.get 27
i64.and
local.get 3
i64.xor
local.set 23
local.get 19
local.get 31
i64.xor
local.tee 3
i64.const 20
i64.shl
local.get 3
i64.const 44
i64.shr_u
i64.or
local.tee 19
i64.const -1
i64.xor
local.get 18
local.get 49
i64.xor
local.tee 3
i64.const 3
i64.shl
local.get 3
i64.const 61
i64.shr_u
i64.or
local.tee 12
i64.and
local.get 5
local.get 30
i64.xor
local.tee 3
i64.const 28
i64.shl
local.get 3
i64.const 36
i64.shr_u
i64.or
local.tee 4
i64.xor
local.set 24
local.get 11
local.get 28
i64.xor
local.tee 3
i64.const 45
i64.shl
local.get 3
i64.const 19
i64.shr_u
i64.or
local.tee 5
local.get 12
i64.const -1
i64.xor
i64.and
local.get 19
i64.xor
local.set 11
local.get 25
local.get 29
i64.xor
local.tee 3
i64.const 61
i64.shl
local.get 3
i64.const 3
i64.shr_u
i64.or
local.tee 3
local.get 5
i64.const -1
i64.xor
i64.and
local.get 12
i64.xor
local.set 25
local.get 3
i64.const -1
i64.xor
local.get 4
i64.and
local.get 5
i64.xor
local.set 26
local.get 4
i64.const -1
i64.xor
local.get 19
i64.and
local.get 3
i64.xor
local.set 14
local.get 29
local.get 48
i64.xor
local.tee 3
i64.const 6
i64.shl
local.get 3
i64.const 58
i64.shr_u
i64.or
local.tee 12
i64.const -1
i64.xor
local.get 9
local.get 30
i64.xor
local.tee 3
i64.const 25
i64.shl
local.get 3
i64.const 39
i64.shr_u
i64.or
local.tee 4
i64.and
local.get 28
local.get 42
i64.xor
local.tee 3
i64.const 1
i64.shl
local.get 3
i64.const 63
i64.shr_u
i64.or
local.tee 9
i64.xor
local.set 15
local.get 31
local.get 32
i64.xor
local.tee 3
i64.const 8
i64.shl
local.get 3
i64.const 56
i64.shr_u
i64.or
local.tee 5
local.get 4
i64.const -1
i64.xor
i64.and
local.get 12
i64.xor
local.set 27
local.get 7
local.get 18
i64.xor
local.tee 3
i64.const 18
i64.shl
local.get 3
i64.const 46
i64.shr_u
i64.or
local.tee 3
local.get 5
i64.const -1
i64.xor
i64.and
local.get 4
i64.xor
local.set 8
local.get 3
i64.const -1
i64.xor
local.get 9
i64.and
local.get 5
i64.xor
local.set 16
local.get 9
i64.const -1
i64.xor
local.get 12
i64.and
local.get 3
i64.xor
local.set 17
local.get 18
local.get 46
i64.xor
local.tee 3
i64.const 36
i64.shl
local.get 3
i64.const 28
i64.shr_u
i64.or
local.tee 7
i64.const -1
i64.xor
local.get 28
local.get 50
i64.xor
local.tee 3
i64.const 10
i64.shl
local.get 3
i64.const 54
i64.shr_u
i64.or
local.tee 4
i64.and
local.get 10
local.get 31
i64.xor
local.tee 3
i64.const 27
i64.shl
local.get 3
i64.const 37
i64.shr_u
i64.or
local.tee 9
i64.xor
local.set 32
local.get 29
local.get 34
i64.xor
local.tee 3
i64.const 15
i64.shl
local.get 3
i64.const 49
i64.shr_u
i64.or
local.tee 5
local.get 4
i64.const -1
i64.xor
i64.and
local.get 7
i64.xor
local.set 19
local.get 30
local.get 33
i64.xor
local.tee 3
i64.const 56
i64.shl
local.get 3
i64.const 8
i64.shr_u
i64.or
local.tee 3
local.get 5
i64.const -1
i64.xor
i64.and
local.get 4
i64.xor
local.set 12
local.get 3
i64.const -1
i64.xor
local.get 9
i64.and
local.get 5
i64.xor
local.set 10
local.get 9
i64.const -1
i64.xor
local.get 7
i64.and
local.get 3
i64.xor
local.set 4
local.get 6
local.get 30
i64.xor
local.tee 3
i64.const 55
i64.shl
local.get 3
i64.const 9
i64.shr_u
i64.or
local.tee 7
i64.const -1
i64.xor
local.get 13
local.get 31
i64.xor
local.tee 3
i64.const 39
i64.shl
local.get 3
i64.const 25
i64.shr_u
i64.or
local.tee 6
i64.and
local.get 29
local.get 44
i64.xor
local.tee 3
i64.const 62
i64.shl
local.get 3
i64.const 2
i64.shr_u
i64.or
local.tee 13
i64.xor
local.set 9
local.get 18
local.get 51
i64.xor
local.tee 3
i64.const 41
i64.shl
local.get 3
i64.const 23
i64.shr_u
i64.or
local.tee 5
local.get 6
i64.const -1
i64.xor
i64.and
local.get 7
i64.xor
local.set 33
local.get 28
local.get 35
i64.xor
local.tee 3
i64.const 2
i64.shl
local.get 3
i64.const 62
i64.shr_u
i64.or
local.tee 3
local.get 5
i64.const -1
i64.xor
i64.and
local.get 6
i64.xor
local.set 6
local.get 3
i64.const -1
i64.xor
local.get 13
i64.and
local.get 5
i64.xor
local.set 5
local.get 13
i64.const -1
i64.xor
local.get 7
i64.and
local.get 3
i64.xor
local.set 3
local.get 1
i32.const 2
i32.add
local.tee 1
i32.const 24
i32.lt_u
br_if 0 (;@1;)
end
local.get 0
local.get 20
i64.store
local.get 0
local.get 21
i64.store offset=8
local.get 0
local.get 37
i64.store offset=16
local.get 0
local.get 22
i64.store offset=24
local.get 0
local.get 23
i64.store offset=32
local.get 0
local.get 24
i64.store offset=40
local.get 0
local.get 11
i64.store offset=48
local.get 0
local.get 25
i64.store offset=56
local.get 2
local.get 26
i64.store
local.get 0
local.get 14
i64.store offset=72
local.get 0
local.get 15
i64.store offset=80
local.get 0
local.get 27
i64.store offset=88
local.get 0
local.get 8
i64.store offset=96
local.get 0
local.get 16
i64.store offset=104
local.get 0
local.get 17
i64.store offset=112
local.get 0
local.get 32
i64.store offset=120
local.get 0
local.get 19
i64.store offset=128
local.get 0
local.get 12
i64.store offset=136
local.get 0
local.get 10
i64.store offset=144
local.get 0
local.get 4
i64.store offset=152
local.get 0
local.get 9
i64.store offset=160
local.get 0
local.get 33
i64.store offset=168
local.get 0
local.get 6
i64.store offset=176
local.get 0
local.get 5
i64.store offset=184
local.get 0
local.get 3
i64.store offset=192)
(func (;1;) (type 2) (param i32 i32 i32)
(local i32 i32 i32 i32 i32 i32 i32 i32 i32 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64 i64)
global.get 0
local.set 8
global.get 0
i32.const 208
i32.add
global.set 0
local.get 8
i32.const 200
i32.add
local.tee 7
i64.const 0
i64.store
local.get 8
local.tee 3
i32.const 0
i32.const 200
call 2
drop
local.get 2
i32.const 136
i32.ge_u
if ;; label = @1
local.get 3
i32.const -64
i32.sub
local.set 4
loop ;; label = @2
local.get 3
local.get 12
local.get 1
i64.load align=1
i64.xor
i64.store
local.get 3
local.get 13
local.get 1
i64.load offset=8 align=1
i64.xor
i64.store offset=8
local.get 3
local.get 18
local.get 1
i64.load offset=16 align=1
i64.xor
i64.store offset=16
local.get 3
local.get 19
local.get 1
i64.load offset=24 align=1
i64.xor
i64.store offset=24
local.get 3
local.get 20
local.get 1
i64.load offset=32 align=1
i64.xor
i64.store offset=32
local.get 3
local.get 21
local.get 1
i64.load offset=40 align=1
i64.xor
i64.store offset=40
local.get 3
local.get 22
local.get 1
i64.load offset=48 align=1
i64.xor
i64.store offset=48
local.get 3
local.get 23
local.get 1
i64.load offset=56 align=1
i64.xor
i64.store offset=56
local.get 4
local.get 24
local.get 1
i32.const -64
i32.sub
i64.load align=1
i64.xor
i64.store
local.get 3
local.get 25
local.get 1
i64.load offset=72 align=1
i64.xor
i64.store offset=72
local.get 3
local.get 14
local.get 1
i64.load offset=80 align=1
i64.xor
i64.store offset=80
local.get 3
local.get 15
local.get 1
i64.load offset=88 align=1
i64.xor
i64.store offset=88
local.get 3
local.get 16
local.get 1
i64.load offset=96 align=1
i64.xor
i64.store offset=96
local.get 3
local.get 17
local.get 1
i64.load offset=104 align=1
i64.xor
i64.store offset=104
local.get 3
local.get 3
i64.load offset=112
local.get 1
i64.load offset=112 align=1
i64.xor
i64.store offset=112
local.get 3
local.get 3
i64.load offset=120
local.get 1
i64.load offset=120 align=1
i64.xor
i64.store offset=120
local.get 3
local.get 3
i64.load offset=128
local.get 1
i64.load offset=128 align=1
i64.xor
i64.store offset=128
local.get 1
i32.const 136
i32.add
local.set 1
local.get 3
call 0
local.get 2
i32.const -136
i32.add
local.tee 2
i32.const 136
i32.ge_u
if ;; label = @3
local.get 3
i64.load
local.set 12
local.get 3
i64.load offset=8
local.set 13
local.get 3
i64.load offset=80
local.set 14
local.get 3
i64.load offset=88
local.set 15
local.get 3
i64.load offset=96
local.set 16
local.get 3
i64.load offset=104
local.set 17
local.get 3
i64.load offset=16
local.set 18
local.get 3
i64.load offset=24
local.set 19
local.get 3
i64.load offset=32
local.set 20
local.get 3
i64.load offset=40
local.set 21
local.get 3
i64.load offset=48
local.set 22
local.get 3
i64.load offset=56
local.set 23
local.get 4
i64.load
local.set 24
local.get 3
i64.load offset=72
local.set 25
br 1 (;@2;)
end
end
end
local.get 2
i32.const 7
i32.gt_u
if (result i32) ;; label = @1
block (result i32) ;; label = @2
local.get 2
i32.const -8
i32.add
local.tee 5
i32.const 3
i32.shr_u
local.set 11
local.get 5
i32.const -8
i32.and
local.set 9
local.get 1
local.set 4
local.get 2
local.set 6
local.get 3
local.set 2
loop ;; label = @3
local.get 2
local.get 2
i64.load
local.get 4
i64.load align=1
i64.xor
i64.store
local.get 2
i32.const 8
i32.add
local.set 2
local.get 4
i32.const 8
i32.add
local.set 4
local.get 6
i32.const -8
i32.add
local.tee 6
i32.const 7
i32.gt_u
br_if 0 (;@3;)
end
local.get 9
i32.const 8
i32.add
local.get 1
i32.add
local.set 1
local.get 5
local.get 9
i32.sub
local.set 6
local.get 11
end
i32.const 1
i32.add
i32.const 3
i32.shl
local.get 3
i32.add
else
local.get 2
local.set 6
local.get 3
end
local.set 5
local.get 6
i32.eqz
if ;; label = @1
local.get 7
i32.const 1
i32.store8
local.get 5
local.get 7
i64.load
local.get 5
i64.load
i64.xor
i64.store
local.get 3
local.get 3
i64.load offset=128
i64.const -9223372036854775808
i64.xor
i64.store offset=128
local.get 3
call 0
local.get 0
local.get 3
i64.load
i64.store
local.get 0
local.get 3
i64.load offset=8
i64.store offset=8
local.get 0
local.get 3
i64.load offset=16
i64.store offset=16
local.get 0
local.get 3
i64.load offset=24
i64.store offset=24
local.get 8
global.set 0
return
end
local.get 7
local.set 2
local.get 6
local.set 4
loop ;; label = @1
local.get 2
local.get 1
i32.load8_s
i32.store8
local.get 2
i32.const 1
i32.add
local.set 2
local.get 1
i32.const 1
i32.add
local.set 1
local.get 4
i32.const -1
i32.add
local.tee 4
br_if 0 (;@1;)
end
local.get 6
local.get 7
i32.add
i32.const 1
i32.store8
local.get 5
local.get 7
i64.load
local.get 5
i64.load
i64.xor
i64.store
local.get 3
local.get 3
i64.load offset=128
i64.const -9223372036854775808
i64.xor
i64.store offset=128
local.get 3
call 0
local.get 0
local.get 3
i64.load
i64.store
local.get 0
local.get 3
i64.load offset=8
i64.store offset=8
local.get 0
local.get 3
i64.load offset=16
i64.store offset=16
local.get 0
local.get 3
i64.load offset=24
i64.store offset=24
local.get 8
global.set 0)
(func (;2;) (type 1) (param i32 i32 i32) (result i32)
(local i32 i32 i32 i32)
local.get 0
local.get 2
i32.add
local.set 4
local.get 1
i32.const 255
i32.and
local.set 3
local.get 2
i32.const 67
i32.ge_s
if ;; label = @1
loop ;; label = @2
local.get 0
i32.const 3
i32.and
if ;; label = @3
local.get 0
local.get 3
i32.store8
local.get 0
i32.const 1
i32.add
local.set 0
br 1 (;@2;)
end
end
local.get 3
i32.const 8
i32.shl
local.get 3
i32.or
local.get 3
i32.const 16
i32.shl
i32.or
local.get 3
i32.const 24
i32.shl
i32.or
local.set 1
local.get 4
i32.const -4
i32.and
local.tee 5
i32.const -64
i32.add
local.set 6
loop ;; label = @2
local.get 0
local.get 6
i32.le_s
if ;; label = @3
local.get 0
local.get 1
i32.store
local.get 0
local.get 1
i32.store offset=4
local.get 0
local.get 1
i32.store offset=8
local.get 0
local.get 1
i32.store offset=12
local.get 0
local.get 1
i32.store offset=16
local.get 0
local.get 1
i32.store offset=20
local.get 0
local.get 1
i32.store offset=24
local.get 0
local.get 1
i32.store offset=28
local.get 0
local.get 1
i32.store offset=32
local.get 0
local.get 1
i32.store offset=36
local.get 0
local.get 1
i32.store offset=40
local.get 0
local.get 1
i32.store offset=44
local.get 0
local.get 1
i32.store offset=48
local.get 0
local.get 1
i32.store offset=52
local.get 0
local.get 1
i32.store offset=56
local.get 0
local.get 1
i32.store offset=60
local.get 0
i32.const -64
i32.sub
local.set 0
br 1 (;@2;)
end
end
loop ;; label = @2
local.get 0
local.get 5
i32.lt_s
if ;; label = @3
local.get 0
local.get 1
i32.store
local.get 0
i32.const 4
i32.add
local.set 0
br 1 (;@2;)
end
end
end
loop ;; label = @1
local.get 0
local.get 4
i32.lt_s
if ;; label = @2
local.get 0
local.get 3
i32.store8
local.get 0
i32.const 1
i32.add
local.set 0
br 1 (;@1;)
end
end
local.get 4
local.get 2
i32.sub)
(global (;0;) (mut i32) (i32.const 2960))
(export "_ethash_keccak256" (func 1))
(data (;0;) (i32.const 1024) "\01\00\00\00\00\00\00\00\82\80\00\00\00\00\00\00\8a\80\00\00\00\00\00\80\00\80\00\80\00\00\00\80\8b\80\00\00\00\00\00\00\01\00\00\80\00\00\00\00\81\80\00\80\00\00\00\80\09\80\00\00\00\00\00\80\8a\00\00\00\00\00\00\00\88\00\00\00\00\00\00\00\09\80\00\80\00\00\00\00\0a\00\00\80\00\00\00\00\8b\80\00\80\00\00\00\00\8b\00\00\00\00\00\00\80\89\80\00\00\00\00\00\80\03\80\00\00\00\00\00\80\02\80\00\00\00\00\00\80\80\00\00\00\00\00\00\80\0a\80\00\00\00\00\00\00\0a\00\00\80\00\00\00\80\81\80\00\80\00\00\00\80\80\80\00\00\00\00\00\80\01\00\00\80\00\00\00\00\08\80\00\80\00\00\00\80"))
.text
.file "keccakf1600.c"
.section .text.ethash_keccakf1600,"",@
.hidden ethash_keccakf1600
.globl ethash_keccakf1600
.type ethash_keccakf1600,@function
ethash_keccakf1600:
.functype ethash_keccakf1600 (i32) -> ()
.local i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i32, i32, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64
local.get 0
i64.load 192
local.set 1
local.get 0
i64.load 184
local.set 2
local.get 0
i64.load 176
local.set 3
local.get 0
i64.load 168
local.set 4
local.get 0
i64.load 160
local.set 5
local.get 0
i64.load 152
local.set 6
local.get 0
i64.load 144
local.set 7
local.get 0
i64.load 136
local.set 8
local.get 0
i64.load 128
local.set 9
local.get 0
i64.load 120
local.set 10
local.get 0
i64.load 112
local.set 11
local.get 0
i64.load 104
local.set 12
local.get 0
i64.load 96
local.set 13
local.get 0
i64.load 88
local.set 14
local.get 0
i64.load 80
local.set 15
local.get 0
i64.load 72
local.set 16
local.get 0
i64.load 64
local.set 17
local.get 0
i64.load 56
local.set 18
local.get 0
i64.load 48
local.set 19
local.get 0
i64.load 40
local.set 20
local.get 0
i64.load 32
local.set 21
local.get 0
i64.load 24
local.set 22
local.get 0
i64.load 16
local.set 23
local.get 0
i64.load 8
local.set 24
local.get 0
i64.load 0
local.set 25
i32.const 0
local.set 26
i32.const round_constants
local.set 27
.LBB0_1:
loop
local.get 10
local.get 5
i64.xor
local.get 15
i64.xor
local.get 20
i64.xor
local.get 25
i64.xor
local.tee 28
i64.const 1
i64.rotl
local.get 7
local.get 2
i64.xor
local.get 12
i64.xor
local.get 17
i64.xor
local.get 22
i64.xor
local.tee 29
i64.xor
local.tee 30
local.get 21
i64.xor
i64.const 27
i64.rotl
local.tee 31
local.get 28
local.get 8
local.get 3
i64.xor
local.get 13
i64.xor
local.get 18
i64.xor
local.get 23
i64.xor
local.tee 32
i64.const 1
i64.rotl
i64.xor
local.tee 28
local.get 14
i64.xor
i64.const 10
i64.rotl
local.tee 33
local.get 9
local.get 4
i64.xor
local.get 14
i64.xor
local.get 19
i64.xor
local.get 24
i64.xor
local.tee 34
i64.const 1
i64.rotl
local.get 6
local.get 1
i64.xor
local.get 11
i64.xor
local.get 16
i64.xor
local.get 21
i64.xor
local.tee 21
i64.xor
local.tee 35
local.get 20
i64.xor
i64.const 36
i64.rotl
local.tee 14
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 36
local.get 28
local.get 24
i64.xor
i64.const 1
i64.rotl
local.tee 20
local.get 32
local.get 21
i64.const 1
i64.rotl
i64.xor
local.tee 24
local.get 12
i64.xor
i64.const 25
i64.rotl
local.tee 12
local.get 34
local.get 29
i64.const 1
i64.rotl
i64.xor
local.tee 29
local.get 18
i64.xor
i64.const 6
i64.rotl
local.tee 18
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 34
i64.xor
local.get 35
local.get 15
i64.xor
i64.const 3
i64.rotl
local.tee 15
local.get 30
local.get 16
i64.xor
i64.const 20
i64.rotl
local.tee 16
i64.const -1
i64.xor
i64.and
local.get 24
local.get 22
i64.xor
i64.const 28
i64.rotl
local.tee 21
i64.xor
local.tee 37
i64.xor
local.get 30
local.get 11
i64.xor
i64.const 39
i64.rotl
local.tee 11
local.get 24
local.get 17
i64.xor
i64.const 55
i64.rotl
local.tee 17
i64.const -1
i64.xor
i64.and
local.get 29
local.get 23
i64.xor
i64.const 62
i64.rotl
local.tee 22
i64.xor
local.tee 38
i64.xor
local.get 29
local.get 13
i64.xor
i64.const 43
i64.rotl
local.tee 13
local.get 28
local.get 19
i64.xor
i64.const 44
i64.rotl
local.tee 19
i64.const -1
i64.xor
i64.and
local.get 35
local.get 25
i64.xor
local.tee 23
i64.xor
local.get 27
i64.load 0
i64.xor
local.tee 39
i64.xor
local.tee 32
i64.const 1
i64.rotl
local.get 35
local.get 10
i64.xor
i64.const 41
i64.rotl
local.tee 10
local.get 22
local.get 28
local.get 4
i64.xor
i64.const 2
i64.rotl
local.tee 4
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 40
local.get 28
local.get 9
i64.xor
i64.const 45
i64.rotl
local.tee 9
local.get 21
local.get 29
local.get 3
i64.xor
i64.const 61
i64.rotl
local.tee 3
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 41
i64.xor
local.get 30
local.get 6
i64.xor
i64.const 8
i64.rotl
local.tee 6
local.get 20
local.get 35
local.get 5
i64.xor
i64.const 18
i64.rotl
local.tee 35
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 42
i64.xor
local.get 23
local.get 30
local.get 1
i64.xor
i64.const 14
i64.rotl
local.tee 1
i64.const -1
i64.xor
i64.and
local.get 24
local.get 7
i64.xor
i64.const 21
i64.rotl
local.tee 5
i64.xor
local.tee 43
i64.xor
local.get 31
local.get 24
local.get 2
i64.xor
i64.const 56
i64.rotl
local.tee 24
i64.const -1
i64.xor
i64.and
local.get 29
local.get 8
i64.xor
i64.const 15
i64.rotl
local.tee 29
i64.xor
local.tee 44
i64.xor
local.tee 2
i64.xor
local.tee 30
local.get 4
local.get 17
local.get 22
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 7
i64.xor
i64.const 14
i64.rotl
local.tee 25
local.get 32
local.get 15
local.get 3
local.get 9
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 22
local.get 33
local.get 24
local.get 29
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 45
i64.xor
local.get 11
local.get 4
local.get 10
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 46
i64.xor
local.get 1
local.get 5
i64.const -1
i64.xor
i64.and
local.get 13
i64.xor
local.tee 4
i64.xor
local.get 35
local.get 6
i64.const -1
i64.xor
i64.and
local.get 12
i64.xor
local.tee 47
i64.xor
local.tee 8
i64.const 1
i64.rotl
i64.xor
local.tee 28
local.get 16
local.get 9
local.get 15
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 9
i64.xor
i64.const 44
i64.rotl
local.tee 32
local.get 39
local.get 14
local.get 29
local.get 33
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 33
local.get 19
local.get 5
local.get 13
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 13
i64.xor
local.get 9
i64.xor
local.get 6
local.get 12
i64.const -1
i64.xor
i64.and
local.get 18
i64.xor
local.tee 12
i64.xor
local.get 10
local.get 11
i64.const -1
i64.xor
i64.and
local.get 17
i64.xor
local.tee 29
i64.xor
local.tee 6
i64.const 1
i64.rotl
local.get 35
local.get 18
local.get 20
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 9
local.get 7
i64.xor
local.get 1
local.get 19
local.get 23
i64.const -1
i64.xor
i64.and
i64.xor
local.tee 11
i64.xor
local.get 16
local.get 21
i64.const -1
i64.xor
i64.and
local.get 3
i64.xor
local.tee 18
i64.xor
local.get 14
local.get 31
i64.const -1
i64.xor
i64.and
local.get 24
i64.xor
local.tee 14
i64.xor
local.tee 24
i64.xor
local.tee 35
i64.xor
local.tee 31
i64.const -1
i64.xor
i64.and
i64.xor
local.set 21
local.get 28
local.get 29
i64.xor
i64.const 2
i64.rotl
local.tee 3
local.get 24
i64.const 1
i64.rotl
local.get 8
i64.xor
local.tee 24
local.get 41
i64.xor
i64.const 55
i64.rotl
local.tee 5
local.get 2
i64.const 1
i64.rotl
local.get 6
i64.xor
local.tee 29
local.get 4
i64.xor
i64.const 62
i64.rotl
local.tee 6
i64.const -1
i64.xor
i64.and
i64.xor
local.set 1
local.get 6
local.get 3
i64.const -1
i64.xor
i64.and
local.get 35
local.get 36
i64.xor
i64.const 41
i64.rotl
local.tee 4
i64.xor
local.set 2
local.get 30
local.get 9
i64.xor
i64.const 39
i64.rotl
local.tee 7
local.get 3
local.get 4
i64.const -1
i64.xor
i64.and
i64.xor
local.set 3
local.get 4
local.get 7
i64.const -1
i64.xor
i64.and
local.get 5
i64.xor
local.set 4
local.get 7
local.get 5
i64.const -1
i64.xor
i64.and
local.get 6
i64.xor
local.set 5
local.get 35
local.get 37
i64.xor
i64.const 36
i64.rotl
local.tee 10
local.get 30
local.get 11
i64.xor
i64.const 27
i64.rotl
local.tee 11
i64.const -1
i64.xor
i64.and
local.get 24
local.get 40
i64.xor
i64.const 56
i64.rotl
local.tee 8
i64.xor
local.set 6
local.get 11
local.get 8
i64.const -1
i64.xor
i64.and
local.get 29
local.get 45
i64.xor
i64.const 15
i64.rotl
local.tee 9
i64.xor
local.set 7
local.get 28
local.get 12
i64.xor
i64.const 10
i64.rotl
local.tee 12
local.get 8
local.get 9
i64.const -1
i64.xor
i64.and
i64.xor
local.set 8
local.get 9
local.get 12
i64.const -1
i64.xor
i64.and
local.get 10
i64.xor
local.set 9
local.get 11
local.get 12
local.get 10
i64.const -1
i64.xor
i64.and
i64.xor
local.set 10
local.get 29
local.get 22
i64.xor
i64.const 6
i64.rotl
local.tee 15
local.get 28
local.get 13
i64.xor
i64.const 1
i64.rotl
local.tee 16
i64.const -1
i64.xor
i64.and
local.get 35
local.get 38
i64.xor
i64.const 18
i64.rotl
local.tee 13
i64.xor
local.set 11
local.get 30
local.get 14
i64.xor
i64.const 8
i64.rotl
local.tee 14
local.get 16
local.get 13
i64.const -1
i64.xor
i64.and
i64.xor
local.set 12
local.get 13
local.get 14
i64.const -1
i64.xor
i64.and
local.get 24
local.get 42
i64.xor
i64.const 25
i64.rotl
local.tee 17
i64.xor
local.set 13
local.get 14
local.get 17
i64.const -1
i64.xor
i64.and
local.get 15
i64.xor
local.set 14
local.get 16
local.get 17
local.get 15
i64.const -1
i64.xor
i64.and
i64.xor
local.set 15
local.get 30
local.get 18
i64.xor
i64.const 20
i64.rotl
local.tee 30
local.get 24
local.get 43
i64.xor
i64.const 28
i64.rotl
local.tee 20
i64.const -1
i64.xor
i64.and
local.get 29
local.get 46
i64.xor
i64.const 61
i64.rotl
local.tee 18
i64.xor
local.set 16
local.get 28
local.get 33
i64.xor
i64.const 45
i64.rotl
local.tee 28
local.get 20
local.get 18
i64.const -1
i64.xor
i64.and
i64.xor
local.set 17
local.get 18
local.get 28
i64.const -1
i64.xor
i64.and
local.get 35
local.get 34
i64.xor
i64.const 3
i64.rotl
local.tee 35
i64.xor
local.set 18
local.get 30
local.get 28
local.get 35
i64.const -1
i64.xor
i64.and
i64.xor
local.set 19
local.get 35
local.get 30
i64.const -1
i64.xor
i64.and
local.get 20
i64.xor
local.set 20
local.get 31
local.get 25
i64.const -1
i64.xor
i64.and
local.get 24
local.get 44
i64.xor
i64.const 21
i64.rotl
local.tee 30
i64.xor
local.set 22
local.get 25
local.get 30
i64.const -1
i64.xor
i64.and
local.get 29
local.get 47
i64.xor
i64.const 43
i64.rotl
local.tee 28
i64.xor
local.set 23
local.get 32
local.get 30
local.get 28
i64.const -1
i64.xor
i64.and
i64.xor
local.set 24
local.get 31
local.get 27
i32.const 8
i32.add
i64.load 0
i64.xor
local.get 28
local.get 32
i64.const -1
i64.xor
i64.and
i64.xor
local.set 25
local.get 27
i32.const 16
i32.add
local.set 27
local.get 26
i32.const 2
i32.add
local.tee 26
i32.const 24
i32.lt_u
br_if 0
end_loop
local.get 0
local.get 1
i64.store 192
local.get 0
local.get 2
i64.store 184
local.get 0
local.get 3
i64.store 176
local.get 0
local.get 4
i64.store 168
local.get 0
local.get 5
i64.store 160
local.get 0
local.get 6
i64.store 152
local.get 0
local.get 7
i64.store 144
local.get 0
local.get 8
i64.store 136
local.get 0
local.get 9
i64.store 128
local.get 0
local.get 10
i64.store 120
local.get 0
local.get 11
i64.store 112
local.get 0
local.get 12
i64.store 104
local.get 0
local.get 13
i64.store 96
local.get 0
local.get 14
i64.store 88
local.get 0
local.get 15
i64.store 80
local.get 0
local.get 16
i64.store 72
local.get 0
local.get 17
i64.store 64
local.get 0
local.get 18
i64.store 56
local.get 0
local.get 19
i64.store 48
local.get 0
local.get 20
i64.store 40
local.get 0
local.get 21
i64.store 32
local.get 0
local.get 22
i64.store 24
local.get 0
local.get 23
i64.store 16
local.get 0
local.get 24
i64.store 8
local.get 0
local.get 25
i64.store 0
end_function
.Lfunc_end0:
.size ethash_keccakf1600, .Lfunc_end0-ethash_keccakf1600
.type round_constants,@object
.section .rodata.round_constants,"",@
.p2align 4
round_constants:
.int64 1
.int64 32898
.int64 -9223372036854742902
.int64 -9223372034707259392
.int64 32907
.int64 2147483649
.int64 -9223372034707259263
.int64 -9223372036854743031
.int64 138
.int64 136
.int64 2147516425
.int64 2147483658
.int64 2147516555
.int64 -9223372036854775669
.int64 -9223372036854742903
.int64 -9223372036854743037
.int64 -9223372036854743038
.int64 -9223372036854775680
.int64 32778
.int64 -9223372034707292150
.int64 -9223372034707259263
.int64 -9223372036854742912
.int64 2147483649
.int64 -9223372034707259384
.size round_constants, 192
.ident "clang version 9.0.0-svn364739-1~exp1+0~20190701101552.184~1.gbp124358 (trunk)"
.section .custom_section.producers,"",@
.int8 1
.int8 12
.ascii "processed-by"
.int8 1
.int8 5
.ascii "clang"
.int8 63
.ascii "9.0.0-svn364739-1~exp1+0~20190701101552.184~1.gbp124358 (trunk)"
.section .rodata.round_constants,"",@
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment