Right now it's almost impossible to use the phone with an enable-debug and enable-optimize build. I don't see why debug builds have to be so slow. We should try to get debug builds to an acceptable speed (maybe within 50% of the opt performance) so it's possible to use the phone with a debug build. And even better we could finally enable tests with debug builds. I want to make this a meta bug where we look at profiles and file followup bugs.
Related: bug 845886, “Make opt + assertions (aka release + debug) the default B2G developer build”.
I think, the debug build should support multiple debug levels, there by categorizing the builds. Having highest debug to verbose, and decreasing the levels to minimum, and finally to none(or release). This would require macro to change all the default debug to verbose and disabled. While having enabled debug build with minimum level, the source code needs to use this new macro with debug level. This would enforce developer to mention at what level the statements in debug it should include.