Unify the logic in SelectAtomicLoadAdd and SelectAtomicLoadArith
authorMichael Liao <michael.liao@intel.com>
Wed, 19 Sep 2012 19:36:58 +0000 (19:36 +0000)
committerMichael Liao <michael.liao@intel.com>
Wed, 19 Sep 2012 19:36:58 +0000 (19:36 +0000)
commitcd9ede9fc00be3f13e6f450b63419ed80f225d48
tree1822c20a55b1bce32ed64d5040b8a3e0047a6fba
parentfc879791f2c6329bb9377ebf8a03608f6590f80e
Unify the logic in SelectAtomicLoadAdd and SelectAtomicLoadArith

- Merge the processing of LOAD_ADD with other atomic load-arith
  operations
- Separate the logic getting target constant for atomic-load-op and add
  an optimization for atomic-load-add on i16 with negative value
- Optimize a minor case for atomic-fetch-add i16 with negative operand. Test
  case is revised.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@164243 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/X86/X86ISelDAGToDAG.cpp
test/CodeGen/X86/atomic_add.ll