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

Side by Side Diff: src/ia32/fast-codegen-ia32.cc

Issue 542053: Fix bug in top-level code generator with global receiver.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 10 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « src/arm/fast-codegen-arm.cc ('k') | src/x64/fast-codegen-x64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 1093 matching lines...) Expand 10 before | Expand all | Expand 10 after
1104 // instruction after the call it is treated specially by the LoadIC code. 1104 // instruction after the call it is treated specially by the LoadIC code.
1105 __ nop(); 1105 __ nop();
1106 // Drop key left on the stack by IC. 1106 // Drop key left on the stack by IC.
1107 __ Drop(1); 1107 __ Drop(1);
1108 // Pop receiver. 1108 // Pop receiver.
1109 __ pop(ebx); 1109 __ pop(ebx);
1110 // Push result (function). 1110 // Push result (function).
1111 __ push(eax); 1111 __ push(eax);
1112 // Push receiver object on stack. 1112 // Push receiver object on stack.
1113 if (prop->is_synthetic()) { 1113 if (prop->is_synthetic()) {
1114 __ push(CodeGenerator::GlobalObject()); 1114 __ mov(ecx, CodeGenerator::GlobalObject());
1115 __ push(FieldOperand(ecx, GlobalObject::kGlobalReceiverOffset));
1115 } else { 1116 } else {
1116 __ push(ebx); 1117 __ push(ebx);
1117 } 1118 }
1118 EmitCallWithStub(expr); 1119 EmitCallWithStub(expr);
1119 } 1120 }
1120 } else { 1121 } else {
1121 // Call to some other expression. If the expression is an anonymous 1122 // Call to some other expression. If the expression is an anonymous
1122 // function literal not called in a loop, mark it as one that should 1123 // function literal not called in a loop, mark it as one that should
1123 // also use the fast code generator. 1124 // also use the fast code generator.
1124 FunctionLiteral* lit = fun->AsFunctionLiteral(); 1125 FunctionLiteral* lit = fun->AsFunctionLiteral();
(...skipping 576 matching lines...) Expand 10 before | Expand all | Expand 10 after
1701 __ add(Operand(edx), Immediate(masm_->CodeObject())); 1702 __ add(Operand(edx), Immediate(masm_->CodeObject()));
1702 __ mov(Operand(esp, 0), edx); 1703 __ mov(Operand(esp, 0), edx);
1703 // And return. 1704 // And return.
1704 __ ret(0); 1705 __ ret(0);
1705 } 1706 }
1706 1707
1707 1708
1708 #undef __ 1709 #undef __
1709 1710
1710 } } // namespace v8::internal 1711 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/fast-codegen-arm.cc ('k') | src/x64/fast-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698