Define DEBUG and TRACE.
Log some diagnostic information when CONTR fails, so we can try to diagnose the problem.