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

Side by Side Diff: src/arm64/lithium-arm64.cc

Issue 1244693002: Add support for adding an external and a tagged pointer (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: updates Created 5 years, 5 months 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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 <sstream> 5 #include <sstream>
6 6
7 #include "src/v8.h" 7 #include "src/v8.h"
8 8
9 #include "src/arm64/lithium-codegen-arm64.h" 9 #include "src/arm64/lithium-codegen-arm64.h"
10 #include "src/hydrogen-osr.h" 10 #include "src/hydrogen-osr.h"
(...skipping 884 matching lines...) Expand 10 before | Expand all | Expand 10 after
895 UseRegisterOrConstantAtStart(instr->BetterRightOperand()); 895 UseRegisterOrConstantAtStart(instr->BetterRightOperand());
896 LInstruction* result = instr->representation().IsSmi() ? 896 LInstruction* result = instr->representation().IsSmi() ?
897 DefineAsRegister(new(zone()) LAddS(left, right)) : 897 DefineAsRegister(new(zone()) LAddS(left, right)) :
898 DefineAsRegister(new(zone()) LAddI(left, right)); 898 DefineAsRegister(new(zone()) LAddI(left, right));
899 if (instr->CheckFlag(HValue::kCanOverflow)) { 899 if (instr->CheckFlag(HValue::kCanOverflow)) {
900 result = AssignEnvironment(result); 900 result = AssignEnvironment(result);
901 } 901 }
902 return result; 902 return result;
903 } else if (instr->representation().IsExternal()) { 903 } else if (instr->representation().IsExternal()) {
904 DCHECK(instr->left()->representation().IsExternal()); 904 DCHECK(instr->left()->representation().IsExternal());
905 DCHECK(instr->right()->representation().IsInteger32()); 905 DCHECK((instr->external_add_type() == AddOfExternalAndInt32 &&
906 instr->right()->representation().IsInteger32()) ||
907 (instr->external_add_type() == AddOfExternalAndTagged &&
908 instr->right()->representation().IsTagged()));
906 DCHECK(!instr->CheckFlag(HValue::kCanOverflow)); 909 DCHECK(!instr->CheckFlag(HValue::kCanOverflow));
907 LOperand* left = UseRegisterAtStart(instr->left()); 910 LOperand* left = UseRegisterAtStart(instr->left());
908 LOperand* right = UseRegisterOrConstantAtStart(instr->right()); 911 LOperand* right = UseRegisterOrConstantAtStart(instr->right());
909 return DefineAsRegister(new(zone()) LAddE(left, right)); 912 return DefineAsRegister(new(zone()) LAddE(left, right));
910 } else if (instr->representation().IsDouble()) { 913 } else if (instr->representation().IsDouble()) {
911 return DoArithmeticD(Token::ADD, instr); 914 return DoArithmeticD(Token::ADD, instr);
912 } else { 915 } else {
913 DCHECK(instr->representation().IsTagged()); 916 DCHECK(instr->representation().IsTagged());
914 return DoArithmeticT(Token::ADD, instr); 917 return DoArithmeticT(Token::ADD, instr);
915 } 918 }
(...skipping 1903 matching lines...) Expand 10 before | Expand all | Expand 10 after
2819 LOperand* context = UseFixed(instr->context(), cp); 2822 LOperand* context = UseFixed(instr->context(), cp);
2820 LOperand* function = UseRegisterAtStart(instr->function()); 2823 LOperand* function = UseRegisterAtStart(instr->function());
2821 LAllocateBlockContext* result = 2824 LAllocateBlockContext* result =
2822 new(zone()) LAllocateBlockContext(context, function); 2825 new(zone()) LAllocateBlockContext(context, function);
2823 return MarkAsCall(DefineFixed(result, cp), instr); 2826 return MarkAsCall(DefineFixed(result, cp), instr);
2824 } 2827 }
2825 2828
2826 2829
2827 } // namespace internal 2830 } // namespace internal
2828 } // namespace v8 2831 } // namespace v8
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/hydrogen-instructions.h » ('j') | src/hydrogen-instructions.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698