[PATCH] D37418: [X86] Use btc/btr/bts to implement xor/and/or that affects a single bit in the upper 32-bits of a 64-bit operation.

Zvi Rackover via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Sep 2 23:13:16 PDT 2017


zvi added a comment.

The code change LGTM, but i'm not sure about the profitability. On recent Intel processors (not sure about AMD), 'or' can be executed at double throughput than 'bt'. Assuming the extra constant move being saved is hoisted out of a hot loop, are we gaining or losing?
For -Os this should be fine.


https://reviews.llvm.org/D37418





More information about the llvm-commits mailing list