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

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

Issue 23480031: Enable preaging of code objects when --optimize-for-size. (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: Limit to pre-age patch. Created 7 years, 3 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
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 191 matching lines...) Expand 10 before | Expand all | Expand 10 after
202 } 202 }
203 } 203 }
204 204
205 info()->set_prologue_offset(masm_->pc_offset()); 205 info()->set_prologue_offset(masm_->pc_offset());
206 if (NeedsEagerFrame()) { 206 if (NeedsEagerFrame()) {
207 ASSERT(!frame_is_built_); 207 ASSERT(!frame_is_built_);
208 frame_is_built_ = true; 208 frame_is_built_ = true;
209 __ push(ebp); // Caller's frame pointer. 209 __ push(ebp); // Caller's frame pointer.
210 __ mov(ebp, esp); 210 __ mov(ebp, esp);
211 info()->AddNoFrameRange(0, masm_->pc_offset()); 211 info()->AddNoFrameRange(0, masm_->pc_offset());
212 __ push(esi); // Callee's context. 212 if (isolate()->is_memory_constrained()) {
213 // This sequence marks pre-aged code.
214 __ push(esi); // Callee's context.
215 __ nop();
216 } else {
217 // This sequence marks non-aged code.
218 __ nop();
219 __ push(esi); // Callee's context
220 }
213 if (info()->IsStub()) { 221 if (info()->IsStub()) {
214 __ push(Immediate(Smi::FromInt(StackFrame::STUB))); 222 __ push(Immediate(Smi::FromInt(StackFrame::STUB)));
215 } else { 223 } else {
216 __ push(edi); // Callee's JS function. 224 __ push(edi); // Callee's JS function.
217 } 225 }
218 } 226 }
219 227
220 if (info()->IsOptimizing() && 228 if (info()->IsOptimizing() &&
221 dynamic_frame_alignment_ && 229 dynamic_frame_alignment_ &&
222 FLAG_debug_code) { 230 FLAG_debug_code) {
(...skipping 6146 matching lines...) Expand 10 before | Expand all | Expand 10 after
6369 FixedArray::kHeaderSize - kPointerSize)); 6377 FixedArray::kHeaderSize - kPointerSize));
6370 __ bind(&done); 6378 __ bind(&done);
6371 } 6379 }
6372 6380
6373 6381
6374 #undef __ 6382 #undef __
6375 6383
6376 } } // namespace v8::internal 6384 } } // namespace v8::internal
6377 6385
6378 #endif // V8_TARGET_ARCH_IA32 6386 #endif // V8_TARGET_ARCH_IA32
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698