简体   繁体   English

编译器可以优化汇编中的函数序言吗?

[英]Can a compiler optimize out a function preamble in assembly?

I am attempting to build a decompiler for x86 executables and was wondering if I can safely assume that function preambles/prologues will remain intact. 我正在尝试为x86可执行文件构建反编译器,并且想知道我是否可以安全地假设函数序言/序言将保持不变。 Is it possible compilers could optimize them out of the assembly? 编译器是否有可能在程序集中优化它们?

是的,可以优化诸如叶子函数(请参阅此处 )之类的东西,以及不使用任何局部变量的任何函数。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何告诉编译器不要优化内联汇编中使用的变量? - How to tell the compiler not to optimize variables used in inline assembly? 为什么编译器不能优化这些无法访问的指令? - Why doesn't the compiler optimize out these unreachable instructions? 编译器可以生成无用的汇编代码吗? - Can a compiler generate useless assembly code? 汇编编译器 - Assembly Compiler 优化嵌套循环以填充数组,以帮助编译器生成高效的 ARM 程序集? - Optimize nested loops for pattern-filling an array, to help the compiler produce efficient ARM assembly? 为什么Rust编译器不能优化Box :: downcast的Err arm? - Why can the Rust compiler not optimize away the Err arm of Box::downcast? 如何优化与 gcc 交叉编译的 LLVM 程序集? - How can I optimize LLVM assembly cross-compiled with gcc? 无法找出程序集x86中的printf函数和使用操作数 - Can't figure out printf function in assembly x86 and working with operands 我如何才能进一步优化此代码? [组装8086字母金字塔] - How I can optimize this code more? [Assembly 8086 letters pyramid] RVCT编译器编译的ARM汇编代码可以在Android设备上运行吗? - Can the ARM assembly code compiled by RVCT compiler run on an android device?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM