Summary
How to resolve "illegal instruction" exception when running an Intel® Software Guard Extensions (Intel® SGX) enclave in 32-bit mode
Description
- Compiled enclave for platform Any CPU | Win32 in Visual Studio*
- Ran application and it crashed
- Visual Studio debugger shows error, Unhandled exception: 0xC000001D: Illegal Instruction, in the signed enclave DLL
Resolution
In Visual Studio, compile the solution for platform x64.
Additional information
Refer to Use of Large Addresses for 32-bit Enclaves for handling large pointer addresses if the enclave must be 32-bit.