[PATCH] D153717: [SCCP] replace valuestate.isConstant with helper isConstant

luxufan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jun 25 08:26:35 PDT 2023

StephenFan created this revision.
StephenFan added a reviewer: nikic.
Herald added a subscriber: hiraditya.
Herald added a project: All.
StephenFan requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
nikic added a comment.

This only makes a difference when the binop returns a poison result, right? I think it's unfortunate that this ends up replacing that with an undef value.

I think it would be good to introduce a new lattice value for poison, which allows us to explicitly represent this and avoid refining poison to undef. Especially in conjunction with D153718 <https://reviews.llvm.org/D153718>, which is kind of weird in we claim no undefs but the result is represented as undef.

  rG LLVM Github Monorepo



-------------- next part --------------
A non-text attachment was scrubbed...
Name: D153717.534313.patch
Type: text/x-patch
Size: 6501 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230625/027487a9/attachment-0001.bin>

More information about the llvm-commits mailing list