------- Comment #7 from mmitchel at gcc dot gnu dot org 2008-10-15 20:20 ------- The comment in the test says:
/* Make sure we didn't eliminate casted types because we thought they were unused. */ If we don't want to do that any more, I think we can just remove this test, rather than passing it special options. But, I think it's odd if I'm in the debugger, looking at code that says: return (X*)y; if I can't say "print (X*)y". If the type is coming from a library, we may not ever create objects of this type. Finally, we use vast amounts of space in object files for debug info, since we emit the same debug info in multiple object files. Trying to optimize by not emitting debug info in this case doesn't seem likely to be a big win given our overall strategy. I don't have any data to support that claim, though. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33429