2019-08-15 06:46:01 +08:00
|
|
|
%use masm
|
|
|
|
|
|
|
|
global fproc, nproc
|
|
|
|
|
|
|
|
bits 64
|
|
|
|
|
|
|
|
_TEXT segment
|
|
|
|
|
|
|
|
fproc proc far
|
|
|
|
mov eax,dword ptr foo
|
|
|
|
mov rdx,offset foo
|
|
|
|
mov ecx,bar[rbx]
|
|
|
|
lea rsi,foo
|
|
|
|
lea rsi,dword ptr foo
|
|
|
|
lea rsi,[foo]
|
|
|
|
lea rsi,dword [foo]
|
2020-07-10 17:46:23 +08:00
|
|
|
mov rdi,gs:[rbx]
|
2019-08-15 06:46:01 +08:00
|
|
|
ret
|
|
|
|
fproc endp
|
|
|
|
|
|
|
|
nproc proc near
|
|
|
|
mov eax,dword ptr foo
|
|
|
|
mov rdx,offset foo
|
|
|
|
mov ecx,bar[rbx]
|
2020-07-10 17:46:23 +08:00
|
|
|
mov rdi,[gs:foo]
|
|
|
|
mov rdi,qword ptr gs:foo
|
2019-08-15 06:46:01 +08:00
|
|
|
ret
|
|
|
|
nproc endp
|
|
|
|
|
|
|
|
_TEXT ends
|
|
|
|
|
|
|
|
_DATA segment
|
|
|
|
nxx dd 80
|
|
|
|
foo dd 100
|
|
|
|
_DATA ends
|
|
|
|
|
2020-07-10 17:46:23 +08:00
|
|
|
segment _BSS nobits
|
2019-08-15 06:46:01 +08:00
|
|
|
bar resd 100
|
2020-07-10 17:46:23 +08:00
|
|
|
xyzzy dd 64 dup (?)
|
2019-08-15 06:46:01 +08:00
|
|
|
_BSS ends
|