作者yshihyu (yshihyu)
看板LinuxDev
标题[问题] callstack for x86/x64
时间Sun Jan 24 16:13:50 2016
https://gist.github.com/anonymous/3f2a1d658af451d1b9f6 // 程式码
gcc -m32 -g test.c -o test
objdump -dS test
https://gist.github.com/anonymous/88ad40d047d19827b202
gcc -g test.c -o test
objdump -dS test
https://gist.github.com/anonymous/95e284285fc3f558c082
请问为什麽分析 call stack gcc 都会加上 -m32 ,
看网路上讲法x64函数参数是用register 传递, 这样不能分析吗?
-m32 是记忆体传递?
如果不加上 -m32 在 x64 分析 call stack 会有什麽问题吗?
谢谢
--
※ 发信站: 批踢踢实业坊(ptt.cc), 来自: 175.180.119.89
※ 文章网址: https://webptt.com/cn.aspx?n=bbs/LinuxDev/M.1453623238.A.1BE.html
1F:→ mshockwave: 不行在64bits机子上用32bits的calling convention吧 01/24 17:19
2F:→ tjjh89017: -m32是把程式编译成32bit 01/24 17:34
3F:推 descent: x86/x64 的 function call convention 不同, 01/24 22:09
4F:→ descent: 单纯看你想看哪一种 01/24 22:10