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/x64/lithium-codegen-x64.cc

Issue 16542003: Enable map dependency to in-flight compilation info. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: put transition maps and initial maps dependency into a separate CL Created 7 years, 6 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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 85
86 86
87 void LCodeGen::FinishCode(Handle<Code> code) { 87 void LCodeGen::FinishCode(Handle<Code> code) {
88 ASSERT(is_done()); 88 ASSERT(is_done());
89 code->set_stack_slots(GetStackSlotCount()); 89 code->set_stack_slots(GetStackSlotCount());
90 code->set_safepoint_table_offset(safepoints_.GetCodeOffset()); 90 code->set_safepoint_table_offset(safepoints_.GetCodeOffset());
91 if (FLAG_weak_embedded_maps_in_optimized_code) { 91 if (FLAG_weak_embedded_maps_in_optimized_code) {
92 RegisterDependentCodeForEmbeddedMaps(code); 92 RegisterDependentCodeForEmbeddedMaps(code);
93 } 93 }
94 PopulateDeoptimizationData(code); 94 PopulateDeoptimizationData(code);
95 for (int i = 0 ; i < prototype_maps_.length(); i++) { 95 info()->CommitDependentMaps(code);
96 prototype_maps_.at(i)->AddDependentCode( 96
97 DependentCode::kPrototypeCheckGroup, code);
98 }
99 for (int i = 0 ; i < transition_maps_.length(); i++) { 97 for (int i = 0 ; i < transition_maps_.length(); i++) {
100 transition_maps_.at(i)->AddDependentCode( 98 transition_maps_.at(i)->AddDependentCode(
101 DependentCode::kTransitionGroup, code); 99 DependentCode::kTransitionGroup, code);
102 } 100 }
103 if (graph()->depends_on_empty_array_proto_elements()) { 101 if (graph()->depends_on_empty_array_proto_elements()) {
104 isolate()->initial_object_prototype()->map()->AddDependentCode( 102 isolate()->initial_object_prototype()->map()->AddDependentCode(
105 DependentCode::kElementsCantBeAddedGroup, code); 103 DependentCode::kElementsCantBeAddedGroup, code);
106 isolate()->initial_array_prototype()->map()->AddDependentCode( 104 isolate()->initial_array_prototype()->map()->AddDependentCode(
107 DependentCode::kElementsCantBeAddedGroup, code); 105 DependentCode::kElementsCantBeAddedGroup, code);
108 } 106 }
(...skipping 4962 matching lines...) Expand 10 before | Expand all | Expand 10 after
5071 5069
5072 5070
5073 void LCodeGen::DoCheckPrototypeMaps(LCheckPrototypeMaps* instr) { 5071 void LCodeGen::DoCheckPrototypeMaps(LCheckPrototypeMaps* instr) {
5074 Register reg = ToRegister(instr->temp()); 5072 Register reg = ToRegister(instr->temp());
5075 5073
5076 ZoneList<Handle<JSObject> >* prototypes = instr->prototypes(); 5074 ZoneList<Handle<JSObject> >* prototypes = instr->prototypes();
5077 ZoneList<Handle<Map> >* maps = instr->maps(); 5075 ZoneList<Handle<Map> >* maps = instr->maps();
5078 5076
5079 ASSERT(prototypes->length() == maps->length()); 5077 ASSERT(prototypes->length() == maps->length());
5080 5078
5081 if (instr->hydrogen()->CanOmitPrototypeChecks()) { 5079 if (!instr->hydrogen()->CanOmitPrototypeChecks()) {
5082 for (int i = 0; i < maps->length(); i++) {
5083 prototype_maps_.Add(maps->at(i), info()->zone());
5084 }
5085 } else {
5086 for (int i = 0; i < prototypes->length(); i++) { 5080 for (int i = 0; i < prototypes->length(); i++) {
5087 __ LoadHeapObject(reg, prototypes->at(i)); 5081 __ LoadHeapObject(reg, prototypes->at(i));
5088 DoCheckMapCommon(reg, maps->at(i), instr); 5082 DoCheckMapCommon(reg, maps->at(i), instr);
5089 } 5083 }
5090 } 5084 }
5091 } 5085 }
5092 5086
5093 5087
5094 void LCodeGen::DoAllocate(LAllocate* instr) { 5088 void LCodeGen::DoAllocate(LAllocate* instr) {
5095 class DeferredAllocate: public LDeferredCode { 5089 class DeferredAllocate: public LDeferredCode {
(...skipping 516 matching lines...) Expand 10 before | Expand all | Expand 10 after
5612 FixedArray::kHeaderSize - kPointerSize)); 5606 FixedArray::kHeaderSize - kPointerSize));
5613 __ bind(&done); 5607 __ bind(&done);
5614 } 5608 }
5615 5609
5616 5610
5617 #undef __ 5611 #undef __
5618 5612
5619 } } // namespace v8::internal 5613 } } // namespace v8::internal
5620 5614
5621 #endif // V8_TARGET_ARCH_X64 5615 #endif // V8_TARGET_ARCH_X64
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698