---
# Step-by-step
0: I32Const 132 @_start
132
5: I32Const 128
128:132
10: I32Load 0
5:132
12: I32Const 23
23:5:132
17: Call {callParamCount = 1, callResultCount = 1}
23: LocalGet 0 @factorial
5
25: I32Const 1
1:5
30: I32LeS
0
31: If
39: LocalGet 0
5
41: LocalGet 0
5:5
43: I32Const 1
1:5:5
48: I32Sub
4:5
49: I32Const 23
23:4:5
54: Call {callParamCount = 1, callResultCount = 1}
23: LocalGet 0 @factorial
4
25: I32Const 1
1:4
30: I32LeS
0
31: If
39: LocalGet 0
4
41: LocalGet 0
4:4
43: I32Const 1
1:4:4
48: I32Sub
3:4
49: I32Const 23
23:3:4
54: Call {callParamCount = 1, callResultCount = 1}
23: LocalGet 0 @factorial
3
25: I32Const 1
1:3
30: I32LeS
0
31: If
39: LocalGet 0
3
41: LocalGet 0
3:3
43: I32Const 1
1:3:3
48: I32Sub
2:3
49: I32Const 23
23:2:3
54: Call {callParamCount = 1, callResultCount = 1}
23: LocalGet 0 @factorial
2
25: I32Const 1
1:2
30: I32LeS
0
31: If
39: LocalGet 0
2
41: LocalGet 0
2:2
43: I32Const 1
1:2:2
48: I32Sub
1:2
49: I32Const 23
23:1:2
54: Call {callParamCount = 1, callResultCount = 1}
23: LocalGet 0 @factorial
1
25: I32Const 1
1:1
30: I32LeS
1
31: If
32: I32Const 1
1
37: Return
1:2
57: I32Mul
2
58: Return
2:3
57: I32Mul
6
58: Return
6:4
57: I32Mul
24
58: Return
24:5
57: I32Mul
120
58: Return
120:132
20: I32Store 0
22: Halt
22: -
---
# Result
numio[0x80]: [] >>> []
numio[0x84]: [] >>> [120]
---
# Overview
## Execution statistics
sim:instruction-count: 61
mem:accesses-total: 153 (reads 93 / writes 60)
layout:sections-size: 59 (text 59 / data 0)
mem:instr-ranges: 0x00..0x3a (59 B)
mem:data-ranges: 0xa8..0xff (88 B)
mem:io-ranges: 0x80..0x87 (8 B)
## Memory layout
```
Kind Range Bytes Accessed Coverage
text 0x000..0x03a 59 0x000..0x03a 100%
x 0x03b..0x07f 69 - 0%
io 0x080..0x087 8 0x080..0x087 100%
x 0x088..0x0a7 32 - 0%
x 0x0a8..0x0ff 88 0x0a8..0x0ff 100%
x 0x100..0x11f 32 - 0%
```
## Memory accesses per instruction
```
Address Exec Read Write Instruction
0x000 1 2 1 I32Const 132 @_start
0x005 1 2 1 I32Const 128
0x00a 1 2 1 I32Load 0
0x00c 1 2 1 I32Const 23
0x011 1 1 2 Call {callParamCount = 1, callResultCount = 1}
0x014 1 2 1 I32Store 0
0x016 1 0 0 Halt
0x017 5 2 1 LocalGet 0 @factorial
0x019 5 2 1 I32Const 1
0x01e 5 1 1 I32LeS
0x01f 4 0 0 If
" 1 3 0 "
0x020 1 2 1 I32Const 1
0x025 1 3 1 Return
0x027 1 1 1 LocalGet 0
" 3 2 1 "
0x029 3 1 1 LocalGet 0
" 1 2 1 "
0x02b 4 2 1 I32Const 1
0x030 4 1 1 I32Sub
0x031 4 2 1 I32Const 23
0x036 4 1 2 Call {callParamCount = 1, callResultCount = 1}
0x039 3 1 1 I32Mul
" 1 2 1 "
0x03a 4 2 1 Return
```
/* comment */