Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(137)

Side by Side Diff: src/compiler/mips64/code-generator-mips64.cc

Issue 1485833003: MIPS:[turbofan] Use Nor instruction for bit negation instead of xori. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/ast/scopes.h" 5 #include "src/ast/scopes.h"
6 #include "src/compiler/code-generator.h" 6 #include "src/compiler/code-generator.h"
7 #include "src/compiler/code-generator-impl.h" 7 #include "src/compiler/code-generator-impl.h"
8 #include "src/compiler/gap-resolver.h" 8 #include "src/compiler/gap-resolver.h"
9 #include "src/compiler/node-matchers.h" 9 #include "src/compiler/node-matchers.h"
10 #include "src/compiler/osr.h" 10 #include "src/compiler/osr.h"
(...skipping 660 matching lines...) Expand 10 before | Expand all | Expand 10 after
671 case kMips64DmodU: 671 case kMips64DmodU:
672 __ Dmodu(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1)); 672 __ Dmodu(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1));
673 break; 673 break;
674 case kMips64And: 674 case kMips64And:
675 __ And(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1)); 675 __ And(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1));
676 break; 676 break;
677 case kMips64Or: 677 case kMips64Or:
678 __ Or(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1)); 678 __ Or(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1));
679 break; 679 break;
680 case kMips64Nor: 680 case kMips64Nor:
681 __ Nor(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1)); 681 if (instr->InputAt(1)->IsRegister()) {
682 __ Nor(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1));
683 } else {
684 DCHECK(i.InputOperand(1).immediate() == 0);
685 __ Nor(i.OutputRegister(), i.InputRegister(0), zero_reg);
686 }
682 break; 687 break;
683 case kMips64Xor: 688 case kMips64Xor:
684 __ Xor(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1)); 689 __ Xor(i.OutputRegister(), i.InputRegister(0), i.InputOperand(1));
685 break; 690 break;
686 case kMips64Clz: 691 case kMips64Clz:
687 __ Clz(i.OutputRegister(), i.InputRegister(0)); 692 __ Clz(i.OutputRegister(), i.InputRegister(0));
688 break; 693 break;
689 case kMips64Dclz: 694 case kMips64Dclz:
690 __ dclz(i.OutputRegister(), i.InputRegister(0)); 695 __ dclz(i.OutputRegister(), i.InputRegister(0));
691 break; 696 break;
(...skipping 1074 matching lines...) Expand 10 before | Expand all | Expand 10 after
1766 padding_size -= v8::internal::Assembler::kInstrSize; 1771 padding_size -= v8::internal::Assembler::kInstrSize;
1767 } 1772 }
1768 } 1773 }
1769 } 1774 }
1770 1775
1771 #undef __ 1776 #undef __
1772 1777
1773 } // namespace compiler 1778 } // namespace compiler
1774 } // namespace internal 1779 } // namespace internal
1775 } // namespace v8 1780 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/mips/instruction-selector-mips.cc ('k') | src/compiler/mips64/instruction-selector-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698