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

Side by Side Diff: src/arm/lithium-codegen-arm.cc

Issue 5964005: Shorten live ranges of argument subexpressions. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 10 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 1591 matching lines...) Expand 10 before | Expand all | Expand 10 after
1602 Abort("DoCallFunction unimplemented."); 1602 Abort("DoCallFunction unimplemented.");
1603 } 1603 }
1604 1604
1605 1605
1606 void LCodeGen::DoCallGlobal(LCallGlobal* instr) { 1606 void LCodeGen::DoCallGlobal(LCallGlobal* instr) {
1607 Abort("DoCallGlobal unimplemented."); 1607 Abort("DoCallGlobal unimplemented.");
1608 } 1608 }
1609 1609
1610 1610
1611 void LCodeGen::DoCallKnownGlobal(LCallKnownGlobal* instr) { 1611 void LCodeGen::DoCallKnownGlobal(LCallKnownGlobal* instr) {
1612 ASSERT(ToRegister(instr->input()).is(r0));
1612 ASSERT(ToRegister(instr->result()).is(r0)); 1613 ASSERT(ToRegister(instr->result()).is(r0));
1614
1615 // The receiver slot in the outgoing arguments holds the global object,
1616 // because that's what the unoptimized code expects if we deoptimize the
1617 // argument subexpressions. Patch it to the global receiver before making
1618 // the call.
1619 int arity = instr->arity(); // Arity does not include receiver.
1620 __ str(r0, MemOperand(sp, arity * kPointerSize));
1621
1613 __ mov(r1, Operand(instr->target())); 1622 __ mov(r1, Operand(instr->target()));
1614 CallKnownFunction(instr->target(), instr->arity(), instr); 1623 CallKnownFunction(instr->target(), arity, instr);
1615 } 1624 }
1616 1625
1617 1626
1618 void LCodeGen::DoCallNew(LCallNew* instr) { 1627 void LCodeGen::DoCallNew(LCallNew* instr) {
1619 ASSERT(ToRegister(instr->input()).is(r1)); 1628 ASSERT(ToRegister(instr->input()).is(r1));
1620 ASSERT(ToRegister(instr->result()).is(r0)); 1629 ASSERT(ToRegister(instr->result()).is(r0));
1621 1630
1622 Handle<Code> builtin(Builtins::builtin(Builtins::JSConstructCall)); 1631 Handle<Code> builtin(Builtins::builtin(Builtins::JSConstructCall));
1623 __ mov(r0, Operand(instr->arity())); 1632 __ mov(r0, Operand(instr->arity()));
1624 CallCode(builtin, RelocInfo::CONSTRUCT_CALL, instr); 1633 CallCode(builtin, RelocInfo::CONSTRUCT_CALL, instr);
(...skipping 533 matching lines...) Expand 10 before | Expand all | Expand 10 after
2158 2167
2159 2168
2160 void LCodeGen::DoOsrEntry(LOsrEntry* instr) { 2169 void LCodeGen::DoOsrEntry(LOsrEntry* instr) {
2161 Abort("DoOsrEntry unimplemented."); 2170 Abort("DoOsrEntry unimplemented.");
2162 } 2171 }
2163 2172
2164 2173
2165 #undef __ 2174 #undef __
2166 2175
2167 } } // namespace v8::internal 2176 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/hydrogen.h » ('j') | src/hydrogen.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698