aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/LiveVariables.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2005-01-19 08:07:05 +0000
committerChris Lattner <sabre@nondot.org>2005-01-19 08:07:05 +0000
commit4053b1e30bee6bbce26b42003527cdc835de8194 (patch)
treed4a1adbf160db6f5a57730c13f6f58f185a0aa70 /lib/CodeGen/LiveVariables.cpp
parentb51f2e3de25b8c543961e1cb7891964b916d1f4e (diff)
Implement Regression/CodeGen/X86/rotate.ll: emit rotate instructions (which
typically cost 1 cycle) instead of shld/shrd instruction (which are typically 6 or more cycles). This also saves code space. For example, instead of emitting: rotr: mov %EAX, DWORD PTR [%ESP + 4] mov %CL, BYTE PTR [%ESP + 8] shrd %EAX, %EAX, %CL ret rotli: mov %EAX, DWORD PTR [%ESP + 4] shrd %EAX, %EAX, 27 ret Emit: rotr32: mov %CL, BYTE PTR [%ESP + 8] mov %EAX, DWORD PTR [%ESP + 4] ror %EAX, %CL ret rotli32: mov %EAX, DWORD PTR [%ESP + 4] ror %EAX, 27 ret We also emit byte rotate instructions which do not have a sh[lr]d counterpart at all. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19692 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/LiveVariables.cpp')
0 files changed, 0 insertions, 0 deletions