aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/MachineSink.cpp
diff options
context:
space:
mode:
authorRobin Morisset <morisset@google.com>2014-09-25 17:27:43 +0000
committerRobin Morisset <morisset@google.com>2014-09-25 17:27:43 +0000
commit810739d17420d914b1a6f239f2ca7d5d82bd5f66 (patch)
tree7ad2d04fba8eb66d74f92bdb0e2a84c972778069 /llvm/lib/CodeGen/MachineSink.cpp
parent8cb2cae03a3bcb88e397dad07c5eb76c5488eb82 (diff)
downloadllvm-810739d17420d914b1a6f239f2ca7d5d82bd5f66.zip
llvm-810739d17420d914b1a6f239f2ca7d5d82bd5f66.tar.gz
llvm-810739d17420d914b1a6f239f2ca7d5d82bd5f66.tar.bz2
Lower idempotent RMWs to fence+load
Summary: I originally tried doing this specifically for X86 in the backend in D5091, but it was rather brittle and generally running too late to be general. Furthermore, other targets may want to implement similar optimizations. So I reimplemented it at the IR-level, fitting it into AtomicExpandPass as it interacts with that pass (which could not be cleanly done before at the backend level). This optimization relies on a new target hook, which is only used by X86 for now, as the correctness of the optimization on other targets remains an open question. If it is found correct on other targets, it should be trivial to enable for them. Details of the optimization are discussed in D5091. Test Plan: make check-all + a new test Reviewers: jfb Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D5422 llvm-svn: 218455
Diffstat (limited to 'llvm/lib/CodeGen/MachineSink.cpp')
0 files changed, 0 insertions, 0 deletions