[PATCH] D112895: [CVP] Canonicalize signed relational comparisons of scalar integers to unsigned comparison predicates

Philip Reames via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 23 16:29:59 PST 2021


reames added a comment.

In D112895#3149487 <https://reviews.llvm.org/D112895#3149487>, @apilipenko wrote:

> Any suggestions for the best place to handle it?

Urgh, this is an annoying case.  We need a mixture of dominating facts relating two variables, and range facts about those same variables.  We don't really have any single place which has both.

I don't think we should revert the patch.  We can construct a similar case where before this patch we'd fail to prove a condition based on a dominating unsigned compare, and now we do.  I think the canonicalization is still warranted and worthwhile.

We almost need a way to remember that we could use either signed or unsigned forms here.  I'm going to give this a bit more thought and see if anything occurs to me.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D112895/new/

https://reviews.llvm.org/D112895



More information about the llvm-commits mailing list