mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-02-13 22:00:14 +00:00
![Saleem Abdulrasool](/assets/img/avatar_default.png)
The clear_cache and enable_execute_stack tests attempt to memcpy the definition of a function into a buffer before executing the function. The problem with this approach is that on some targets (ARM with thumb mode compilation, MIPS with MIPS16 codegen or uMIPS), you would use a pointer which is incorrect (it would be off-by-one) due to the ISA selection being encoded into the address. This ensures that the function address is retrieved correctly in all cases. llvm-svn: 225215