aboutsummaryrefslogtreecommitdiff
path: root/ia32/stack.sts
blob: e884098ace122590f2b55acd13ae72f8a60a8fb6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
defasm top
    # 54 ?'                             ; push esp
next

defasm ref
    # 58 ?'                             ; pop eax
    # c1 ?' # e0 ?' # 2 ?'              ; shl eax, 2
    # 01 ?' # e0 ?'                     ; add eax, esp
    # 50 ?'                             ; push eax
next

defasm get
    # 58 ?'                             ; pop eax
    # 8b ?' # 4 ?' # 84 ?'              ; mov eax, [esp + 4 * eax]
    # 50 ?'                             ; push eax
next

defasm set
    # 5b ?'                             ; pop ebx
    # 58 ?'                             ; pop eax
    # 89 ?' # 04 ?' # 9c ?'             ; mov [esp + 4 * ebx], eax
next

defasm drop
    # 58 ?'                             ; pop eax
next

defasm dup
    # ff ?' # 34 ?' # 24 ?'             ; push dword [esp]
next

defasm over
   # ff ?' # 74 ?' # 24 ?' # 4 ?'       ; push dword [esp + 4]
next

defasm swap
    # 58 ?'                             ; pop eax
    # 5b ?'                             ; pop ebx
    # 50 ?'                             ; push eax
    # 53 ?'                             ; push ebx
next