[turbofan]: More optimizations to add and subtract operations on x64
authorDaniel Clifford <danno@chromium.org>
Thu, 20 Nov 2014 13:48:34 +0000 (14:48 +0100)
committerDaniel Clifford <danno@chromium.org>
Thu, 20 Nov 2014 13:48:46 +0000 (13:48 +0000)
commit5a494cf00ca4626758cc41e0ca800ebb0bff3a9b
treec6423b88dbe3dd97251b645dade0cecb7ce1f551
parent481772acdd6cded6b3320cdf7cde1084a01a1b22
[turbofan]: More optimizations to add and subtract operations on x64

- Use "leal" for subtraction of integer constant when non-constant input to
  subtract is used more than once.
- Use "incl", "decl", and "addl" when they are smaller/cheaper than their
  leal/addl/subl equivalant.

R=titzer@chromium.org

Review URL: https://codereview.chromium.org/738073002

Cr-Commit-Position: refs/heads/master@{#25439}
src/compiler/x64/code-generator-x64.cc
src/compiler/x64/instruction-codes-x64.h
src/compiler/x64/instruction-selector-x64.cc
test/unittests/compiler/x64/instruction-selector-x64-unittest.cc