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

Side by Side Diff: src/ia32/lithium-codegen-ia32.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 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 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 ASSERT(is_done()); 102 ASSERT(is_done());
103 code->set_stack_slots(GetStackSlotCount()); 103 code->set_stack_slots(GetStackSlotCount());
104 code->set_safepoint_table_offset(safepoints_.GetCodeOffset()); 104 code->set_safepoint_table_offset(safepoints_.GetCodeOffset());
105 if (FLAG_weak_embedded_maps_in_optimized_code) { 105 if (FLAG_weak_embedded_maps_in_optimized_code) {
106 RegisterDependentCodeForEmbeddedMaps(code); 106 RegisterDependentCodeForEmbeddedMaps(code);
107 } 107 }
108 PopulateDeoptimizationData(code); 108 PopulateDeoptimizationData(code);
109 if (!info()->IsStub()) { 109 if (!info()->IsStub()) {
110 Deoptimizer::EnsureRelocSpaceForLazyDeoptimization(code); 110 Deoptimizer::EnsureRelocSpaceForLazyDeoptimization(code);
111 } 111 }
112 for (int i = 0 ; i < prototype_maps_.length(); i++) { 112 info()->CommitDependentMaps(code);
113 prototype_maps_.at(i)->AddDependentCode( 113
114 DependentCode::kPrototypeCheckGroup, code);
115 }
116 for (int i = 0 ; i < transition_maps_.length(); i++) { 114 for (int i = 0 ; i < transition_maps_.length(); i++) {
117 transition_maps_.at(i)->AddDependentCode( 115 transition_maps_.at(i)->AddDependentCode(
118 DependentCode::kTransitionGroup, code); 116 DependentCode::kTransitionGroup, code);
119 } 117 }
120 if (graph()->depends_on_empty_array_proto_elements()) { 118 if (graph()->depends_on_empty_array_proto_elements()) {
121 isolate()->initial_object_prototype()->map()->AddDependentCode( 119 isolate()->initial_object_prototype()->map()->AddDependentCode(
122 DependentCode::kElementsCantBeAddedGroup, code); 120 DependentCode::kElementsCantBeAddedGroup, code);
123 isolate()->initial_array_prototype()->map()->AddDependentCode( 121 isolate()->initial_array_prototype()->map()->AddDependentCode(
124 DependentCode::kElementsCantBeAddedGroup, code); 122 DependentCode::kElementsCantBeAddedGroup, code);
125 } 123 }
(...skipping 5855 matching lines...) Expand 10 before | Expand all | Expand 10 after
5981 5979
5982 5980
5983 void LCodeGen::DoCheckPrototypeMaps(LCheckPrototypeMaps* instr) { 5981 void LCodeGen::DoCheckPrototypeMaps(LCheckPrototypeMaps* instr) {
5984 Register reg = ToRegister(instr->temp()); 5982 Register reg = ToRegister(instr->temp());
5985 5983
5986 ZoneList<Handle<JSObject> >* prototypes = instr->prototypes(); 5984 ZoneList<Handle<JSObject> >* prototypes = instr->prototypes();
5987 ZoneList<Handle<Map> >* maps = instr->maps(); 5985 ZoneList<Handle<Map> >* maps = instr->maps();
5988 5986
5989 ASSERT(prototypes->length() == maps->length()); 5987 ASSERT(prototypes->length() == maps->length());
5990 5988
5991 if (instr->hydrogen()->CanOmitPrototypeChecks()) { 5989 if (!instr->hydrogen()->CanOmitPrototypeChecks()) {
5992 for (int i = 0; i < maps->length(); i++) {
5993 prototype_maps_.Add(maps->at(i), info()->zone());
5994 }
5995 } else {
5996 for (int i = 0; i < prototypes->length(); i++) { 5990 for (int i = 0; i < prototypes->length(); i++) {
5997 __ LoadHeapObject(reg, prototypes->at(i)); 5991 __ LoadHeapObject(reg, prototypes->at(i));
5998 DoCheckMapCommon(reg, maps->at(i), instr); 5992 DoCheckMapCommon(reg, maps->at(i), instr);
5999 } 5993 }
6000 } 5994 }
6001 } 5995 }
6002 5996
6003 5997
6004 void LCodeGen::DoAllocate(LAllocate* instr) { 5998 void LCodeGen::DoAllocate(LAllocate* instr) {
6005 class DeferredAllocate: public LDeferredCode { 5999 class DeferredAllocate: public LDeferredCode {
(...skipping 508 matching lines...) Expand 10 before | Expand all | Expand 10 after
6514 FixedArray::kHeaderSize - kPointerSize)); 6508 FixedArray::kHeaderSize - kPointerSize));
6515 __ bind(&done); 6509 __ bind(&done);
6516 } 6510 }
6517 6511
6518 6512
6519 #undef __ 6513 #undef __
6520 6514
6521 } } // namespace v8::internal 6515 } } // namespace v8::internal
6522 6516
6523 #endif // V8_TARGET_ARCH_IA32 6517 #endif // V8_TARGET_ARCH_IA32
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698