[PATCH] D40297: [RegisterCoalescer] Add verification method to check LiveInterval Segments

David Stuttard via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 28 02:18:30 PST 2017


dstuttard added a comment.

The intent of this code is really to allow anyone doing debug to insert a check anywhere in the code. In particular, for the problems I was looking at I needed to check the live intervals after each change made in order to pinpoint where an error was being introduced. As implemented here (with the check after coalescing) it looks redundant, so having that extra check is probably useless.
Running a verification phase after coalescing is sometimes too late, and indeed may well have asserted before this point.

I agree that duplicating code isn't desirable, so the suggestion of re-factoring the existing MachineVerifier code to allow invocations in this way is probably better. I'll take a look.


https://reviews.llvm.org/D40297





More information about the llvm-commits mailing list