llvm/test
Craig Topper b3518390c1 [InstSimplify] Handle (~A & ~B) | (~A ^ B) -> ~A ^ B
The code Sanjay Patel moved over from InstCombine doesn't work properly if the 'and' has both inputs as nots because we used a commuted op matcher on the 'and' first. But this will bind to the first 'not' on 'and' when there could be two 'not's. InstCombine could rely on DeMorgan to ensure the 'and' wouldn't have two 'not's eventually, but InstSimplify can't rely on that.

This patch matches the xor first then checks for the ands and allows a not of either operand of the xor.

Differential Revision: https://reviews.llvm.org/D32458

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@301329 91177308-0d34-0410-b5e6-96231b3b80d8
2017-04-25 17:01:32 +00:00
..
Analysis [IVUsers] Don't bail out of normalizing non-affine add recs 2017-04-25 06:53:25 +00:00
Assembler
Bindings
Bitcode PR32382: Fix emitting complex DWARF expressions. 2017-04-18 01:21:53 +00:00
BugPoint
CodeGen Resubmit r301309: [DebugInfo][X86] Fix handling of DBG_VALUE's in post-RA scheduler. 2017-04-25 15:39:57 +00:00
DebugInfo Add a testcase for DIExpression(DW_OP_stack_value) 2017-04-24 18:11:38 +00:00
Examples
ExecutionEngine
Feature
FileCheck
Instrumentation [asan] Let the frontend disable gc-sections optimization for asan globals. 2017-04-24 19:34:13 +00:00
Integer
JitListener
LibDriver
Linker
LTO
MC [AMDGPU][mc][tests][NFC] Bulk ISA tests: update for Gfx7/Gfx8, add for Gfx9. 2017-04-24 20:42:27 +00:00
Object
ObjectYAML
Other Handle invariant.group.barrier in BasicAA 2017-04-24 19:37:17 +00:00
SymbolRewriter
TableGen [globalisel][tablegen] Add support for RegisterOperand. 2017-04-22 15:53:21 +00:00
ThinLTO/X86 Bitcode: Add a string table to the bitcode format. 2017-04-17 17:51:36 +00:00
tools [llvm-pdbdump] Merge functionality of graphical and text dumpers. 2017-04-24 17:47:52 +00:00
Transforms [InstSimplify] Handle (~A & ~B) | (~A ^ B) -> ~A ^ B 2017-04-25 17:01:32 +00:00
Unit
Verifier
YAMLParser
.clang-format
CMakeLists.txt Add a dependency from llvm/test to llvm-cvtres. 2017-04-21 20:45:11 +00:00
lit.cfg
lit.site.cfg.in
TestRunner.sh