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

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

Issue 186673004: MIPS: Push safepoint registers in deferred number-to-i/u only on-demand. (Closed) Base URL: https://github.com/v8/v8.git@gbl
Patch Set: Created 6 years, 9 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
« no previous file with comments | « src/mips/lithium-mips.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1753 matching lines...) Expand 10 before | Expand all | Expand 10 after
1764 LOperand* value = UseRegister(instr->value()); 1764 LOperand* value = UseRegister(instr->value());
1765 LDoubleToI* res = new(zone()) LDoubleToI(value); 1765 LDoubleToI* res = new(zone()) LDoubleToI(value);
1766 return AssignEnvironment(DefineAsRegister(res)); 1766 return AssignEnvironment(DefineAsRegister(res));
1767 } 1767 }
1768 } else if (from.IsInteger32()) { 1768 } else if (from.IsInteger32()) {
1769 info()->MarkAsDeferredCalling(); 1769 info()->MarkAsDeferredCalling();
1770 if (to.IsTagged()) { 1770 if (to.IsTagged()) {
1771 HValue* val = instr->value(); 1771 HValue* val = instr->value();
1772 LOperand* value = UseRegisterAtStart(val); 1772 LOperand* value = UseRegisterAtStart(val);
1773 if (val->CheckFlag(HInstruction::kUint32)) { 1773 if (val->CheckFlag(HInstruction::kUint32)) {
1774 LNumberTagU* result = new(zone()) LNumberTagU(value); 1774 LOperand* temp1 = TempRegister();
1775 LOperand* temp2 = TempRegister();
1776 LNumberTagU* result = new(zone()) LNumberTagU(value, temp1, temp2);
1775 return AssignEnvironment(AssignPointerMap(DefineAsRegister(result))); 1777 return AssignEnvironment(AssignPointerMap(DefineAsRegister(result)));
1776 } else if (val->HasRange() && val->range()->IsInSmiRange()) { 1778 } else if (val->HasRange() && val->range()->IsInSmiRange()) {
1777 return DefineAsRegister(new(zone()) LSmiTag(value)); 1779 return DefineAsRegister(new(zone()) LSmiTag(value));
1778 } else { 1780 } else {
1779 LNumberTagI* result = new(zone()) LNumberTagI(value); 1781 LOperand* temp1 = TempRegister();
1782 LOperand* temp2 = TempRegister();
1783 LNumberTagI* result = new(zone()) LNumberTagI(value, temp1, temp2);
1780 return AssignEnvironment(AssignPointerMap(DefineAsRegister(result))); 1784 return AssignEnvironment(AssignPointerMap(DefineAsRegister(result)));
1781 } 1785 }
1782 } else if (to.IsSmi()) { 1786 } else if (to.IsSmi()) {
1783 HValue* val = instr->value(); 1787 HValue* val = instr->value();
1784 LOperand* value = UseRegister(val); 1788 LOperand* value = UseRegister(val);
1785 LInstruction* result = val->CheckFlag(HInstruction::kUint32) 1789 LInstruction* result = val->CheckFlag(HInstruction::kUint32)
1786 ? DefineAsRegister(new(zone()) LUint32ToSmi(value)) 1790 ? DefineAsRegister(new(zone()) LUint32ToSmi(value))
1787 : DefineAsRegister(new(zone()) LInteger32ToSmi(value)); 1791 : DefineAsRegister(new(zone()) LInteger32ToSmi(value));
1788 if (val->HasRange() && val->range()->IsInSmiRange()) { 1792 if (val->HasRange() && val->range()->IsInSmiRange()) {
1789 return result; 1793 return result;
(...skipping 616 matching lines...) Expand 10 before | Expand all | Expand 10 after
2406 2410
2407 2411
2408 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2412 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2409 LOperand* object = UseRegister(instr->object()); 2413 LOperand* object = UseRegister(instr->object());
2410 LOperand* index = UseRegister(instr->index()); 2414 LOperand* index = UseRegister(instr->index());
2411 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); 2415 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index));
2412 } 2416 }
2413 2417
2414 2418
2415 } } // namespace v8::internal 2419 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/mips/lithium-mips.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698