In present-day debug-info, when you delete all instructions, you delete all their debug-info with it because debug-info is stored in instructions. With debug-info stored in DPValue objects however, deleting instructions causes DPValue objects to clump together into a large blob of debug-info that hangs around in the block, as nothing has explicitly deleted it. To restore this behaviour, scatter calls to dropDbgValues around in places that used to delete chunks of dbg.values, for example during stripDebugInfo and in the code that deletes everything after an Unreachable instruction. DCE is another example. The tests with --try... added to them are new scenarios where we can now correctly replicate the "normal" debug-info behaviour. Alas, there's no explicit test for the opt -strip-debug option though (in dbg.value mode or DPValue mode).
25 KiB
25 KiB