[PATCH] D55694: GlobalISel: Improve crash on invalid mapping
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Dec 16 22:38:32 PST 2018
arsenm added a comment.
In D55694#1332254 <https://reviews.llvm.org/D55694#1332254>, @bogner wrote:
> I don’t think I understand what this is trying to accomplish. ISTM that this will now hit a null dereference on line 123 when we read BreadDown in the case that NumBreakDowns is zero, but this is to avoid hitting an assert somewhere else? If this is to make it clearer as to what’s failing, shouldn’t we assert NumBreakDowns != 0 here instead of just hoping to crash on a null dereference?
No, that is what this avoids. Right now there is a null dereference on line 123. Now this function exits, so this continues until it hits
Assertion failed: (getOperandMapping(Idx).isValid() && "We must have a mapping for reg operands"), function verify, file ../lib/CodeGen/GlobalISel/RegisterBankInfo.cpp, line 572.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D55694/new/
https://reviews.llvm.org/D55694
More information about the llvm-commits
mailing list