Troubleshoot Failures in Deployed Code
If your deployed code fails, consider regenerating the code with run-time error detection enabled. When you enable run-time error detection, the generated code includes code that detects and reports errors, such as out-of-bounds array indexing. If the code detects one of these errors, it reports a message and terminates the program. Running the code that includes the error checks helps you to see if one of these errors caused the failure.
Run-time error detection can affect the performance of the generated code. If performance is a consideration for your application, when you finish troubleshooting, regenerate the code with run-time error detection disabled.