四时宝库

程序员的知识宝库

64位汇编语言之Hello word

option casemap:none
OPTION DOTNAME
include win64.inc
include ksamd64.inc
include Macros\x64macros.inc
include Macros\x64calling.inc
include Macros\vasily.inc
include Macros\ucmacros.inc
include user32.inc
includelib User32.Lib
.data
hello	db "HelloWord!",0

WSTR whello, "wide_char"
WSTR fastcall, "fastcall"
.code

WinMain proc  hInst:qword,hPrevInst:qword,CmdLine:qword,CmdShow:qword

	
	invoke MessageBox,0,addr hello,addr hello,MB_OKCANCEL
	.if rax == IDOK
		
				invoke MessageBoxW,0,addr whello,addr whello,MB_OK
		
				mov rcx,0
				lea rdx,fastcall
				lea r8,fastcall
				mov r9,MB_OK
				call MessageBoxW
		
		
	.endif
	
	ret

WinMain endp
end






;编译器下载地址:
;https://pan.baidu.com/s/16OIcuBgOgieCOfhsc83a_Q
;提取码:masm
;windbg调试器下载地址:
;https://pan.baidu.com/s/1ISV_FcK1mGG41F1KdhsmTA
;提取码:masm

发表评论:

控制面板
您好,欢迎到访网站!
  查看权限
网站分类
最新留言
    友情链接