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

Side by Side Diff: src/code-stubs-hydrogen.cc

Issue 606083004: Fulfill some code serializer related TODOs. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 2 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/code-stubs.cc ('k') | src/lithium.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 "src/v8.h" 5 #include "src/v8.h"
6 6
7 #include "src/bailout-reason.h" 7 #include "src/bailout-reason.h"
8 #include "src/code-stubs.h" 8 #include "src/code-stubs.h"
9 #include "src/field-index.h" 9 #include "src/field-index.h"
10 #include "src/hydrogen.h" 10 #include "src/hydrogen.h"
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after
264 if (stub->IsUninitialized() && descriptor.has_miss_handler()) { 264 if (stub->IsUninitialized() && descriptor.has_miss_handler()) {
265 DCHECK(!descriptor.stack_parameter_count().is_valid()); 265 DCHECK(!descriptor.stack_parameter_count().is_valid());
266 return stub->GenerateLightweightMissCode(descriptor.miss_handler()); 266 return stub->GenerateLightweightMissCode(descriptor.miss_handler());
267 } 267 }
268 base::ElapsedTimer timer; 268 base::ElapsedTimer timer;
269 if (FLAG_profile_hydrogen_code_stub_compilation) { 269 if (FLAG_profile_hydrogen_code_stub_compilation) {
270 timer.Start(); 270 timer.Start();
271 } 271 }
272 CodeStubGraphBuilder<Stub> builder(isolate, stub); 272 CodeStubGraphBuilder<Stub> builder(isolate, stub);
273 LChunk* chunk = OptimizeGraph(builder.CreateGraph()); 273 LChunk* chunk = OptimizeGraph(builder.CreateGraph());
274 // TODO(yangguo) remove this once the code serializer handles code stubs.
275 if (FLAG_serialize_toplevel) chunk->info()->PrepareForSerializing();
276 Handle<Code> code = chunk->Codegen(); 274 Handle<Code> code = chunk->Codegen();
277 if (FLAG_profile_hydrogen_code_stub_compilation) { 275 if (FLAG_profile_hydrogen_code_stub_compilation) {
278 OFStream os(stdout); 276 OFStream os(stdout);
279 os << "[Lazy compilation of " << stub << " took " 277 os << "[Lazy compilation of " << stub << " took "
280 << timer.Elapsed().InMillisecondsF() << " ms]" << std::endl; 278 << timer.Elapsed().InMillisecondsF() << " ms]" << std::endl;
281 } 279 }
282 return code; 280 return code;
283 } 281 }
284 282
285 283
(...skipping 1716 matching lines...) Expand 10 before | Expand all | Expand 10 after
2002 2000
2003 // Probe the stub cache. 2001 // Probe the stub cache.
2004 Code::Flags flags = Code::RemoveTypeAndHolderFromFlags( 2002 Code::Flags flags = Code::RemoveTypeAndHolderFromFlags(
2005 Code::ComputeHandlerFlags(Code::LOAD_IC)); 2003 Code::ComputeHandlerFlags(Code::LOAD_IC));
2006 Add<HTailCallThroughMegamorphicCache>(receiver, name, flags); 2004 Add<HTailCallThroughMegamorphicCache>(receiver, name, flags);
2007 2005
2008 // We never continue. 2006 // We never continue.
2009 return graph()->GetConstant0(); 2007 return graph()->GetConstant0();
2010 } 2008 }
2011 } } // namespace v8::internal 2009 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/code-stubs.cc ('k') | src/lithium.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698