Add proper support for debug mode simulations with CVODE and IDA.