[Attributor] Extend the AAValueSimplify compare simplification logic
authorJohannes Doerfert <johannes@jdoerfert.de>
Thu, 15 Jul 2021 20:41:46 +0000 (15:41 -0500)
committerJohannes Doerfert <johannes@jdoerfert.de>
Tue, 20 Jul 2021 05:35:14 +0000 (00:35 -0500)
commit5fbb51d8d58fef32a88c9d9d54f094db076c2c2a
tree064d73cb84ca8ee70dc96c2750fb1934b06d65a6
parent9c00aabd6090d4cb9c31342b6c7ce9bd00ae9558
[Attributor] Extend the AAValueSimplify compare simplification logic

We first simplify the operands of a compare and then reason on the
simplified versions, e.g., with AANonNull.

This does improve the simplification capabilities but also fixes a
potential problem that has not yet been observed by simplifying the
operands first.
16 files changed:
llvm/lib/Transforms/IPO/AttributorAttributes.cpp
llvm/test/Transforms/Attributor/ArgumentPromotion/alignment.ll
llvm/test/Transforms/Attributor/ArgumentPromotion/inalloca.ll
llvm/test/Transforms/Attributor/IPConstantProp/2009-09-24-byval-ptr.ll
llvm/test/Transforms/Attributor/IPConstantProp/PR26044.ll
llvm/test/Transforms/Attributor/IPConstantProp/openmp_parallel_for.ll
llvm/test/Transforms/Attributor/align.ll
llvm/test/Transforms/Attributor/cgscc_bugs.ll
llvm/test/Transforms/Attributor/depgraph.ll
llvm/test/Transforms/Attributor/heap_to_stack.ll
llvm/test/Transforms/Attributor/heap_to_stack_gpu.ll
llvm/test/Transforms/Attributor/liveness.ll
llvm/test/Transforms/Attributor/memory_locations.ll
llvm/test/Transforms/Attributor/read_write_returned_arguments_scc.ll
llvm/test/Transforms/Attributor/value-simplify-pointer-info.ll
llvm/test/Transforms/Attributor/value-simplify.ll