OSDN Git Service

InstCombine: Rely on cmpxchg's return code when it's strong
authorDavid Majnemer <david.majnemer@gmail.com>
Thu, 6 Nov 2014 23:23:30 +0000 (23:23 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Thu, 6 Nov 2014 23:23:30 +0000 (23:23 +0000)
commit98066413ca49bc8bcca445bbd5bd3620c5ae49fc
treeab9848b2b8faa33dff2657d987245cf4a6bc75c2
parent7d60fe047a8ead7ac64d8b9b94ad64f2ee9d2f66
InstCombine: Rely on cmpxchg's return code when it's strong

Comparing the result of a cmpxchg instruction can be replaced with an
extractvalue of the cmpxchg success indicator.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221498 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/InstCombine/InstCombineCompares.cpp
test/Transforms/InstCombine/icmp.ll