libraries:machine_code

Machine Code

Machine Code (referred to as "mcode") is the process of embedding code written in a different language (usually C) into AHK code, and then calling it with the DllCall() function. MCode is especially useful for performance critical operations like physics calculation or image processing, since compiled C code is much faster than the compiled C++ code which is used to interpret regular AHK code. However, due to the unique constraints of code being executed inside of AHK by DllCall(), special tools are needed to compile any old C/C++ code into MCode. For guidance on how to use Machine Code tools, see the Machine Code guide page.