Lines Matching defs:map

627     // If the function has allocated the initial map replace it with a
637 // Put the value in the initial map field until an initial map is needed.
638 // At that point, a new initial map is created and the prototype is put
639 // into the initial map where it belongs.
649 // Deoptimize all code that embeds the previous initial map.
653 // Put the value in the initial map field until an initial map is
654 // needed. At that point, a new initial map is created and the
655 // prototype is put into the initial map where it belongs.
673 // If the value is not a JSReceiver, store the value in the map's
678 // Copy the map so this does not affect unrelated functions.
679 // Remove map transitions because they point to maps with a
682 Map::Copy(isolate, handle(function->map(), isolate), "SetPrototype");
700 function->map().set_has_non_instance_prototype(false);
707 Handle<Map> map, Handle<HeapObject> prototype) {
708 SetInitialMap(isolate, function, map, prototype, function);
712 Handle<Map> map, Handle<HeapObject> prototype,
714 if (map->prototype() != *prototype) {
715 Map::SetPrototype(isolate, map, prototype);
717 map->SetConstructor(*constructor);
718 function->set_prototype_or_initial_map(*map, kReleaseStore);
720 LOG(isolate, MapEvent("InitialMap", Handle<Map>(), map, "",
737 // the initial map (e.g. it could have triggered an optimized compilation
741 // Create a new map with the size and number of in-object properties suggested
757 Handle<Map> map = isolate->factory()->NewMap(instance_type, instance_size,
768 DCHECK(map->has_fast_object_elements());
770 // Finally link initial map and constructor function.
772 JSFunction::SetInitialMap(isolate, function, map, prototype);
773 map->StartInobjectSlackTracking();
915 // Check that |function|'s initial map still in sync with the |constructor|,
916 // otherwise we must create a new initial map for |function|.
924 // Create a new map with the size and number of in-object properties
927 // Link initial map and constructor function if the new.target is actually a
953 Handle<Map> map =
956 map->set_new_target_is_base(false);
958 JSFunction::SetInitialMap(isolate, new_target, map, prototype, constructor);
960 map->set_construction_counter(Map::kNoSlackTracking);
961 map->StartInobjectSlackTracking();
977 // Fast case, new.target is a subclass of constructor. The map is cacheable
988 // Slow path, new.target is either a proxy or can't cache the map.
1008 // prototype, hence we have to reload the initial map.
1032 Handle<Map> map = Map::CopyInitialMap(isolate, constructor_initial_map);
1033 map->set_new_target_is_base(false);
1035 if (map->prototype() != *prototype)
1036 Map::SetPrototype(isolate, map, Handle<HeapObject>::cast(prototype));
1037 map->SetConstructor(*constructor);
1038 return map;
1073 Handle<Map> map =
1079 TypedArrayElementsKindToConstructorIndex(map->elements_kind());
1082 TypedArrayElementsKindToRabGsabCtorIndex(map->elements_kind());
1087 // This only happens when subclassing TypedArrays. Create a new map with the
1088 // corresponding RAB / GSAB ElementsKind. Note: the map is not cached and
1089 // reused -> every array gets a unique map, making ICs slow.
1090 Handle<Map> rab_gsab_map = Map::Copy(isolate, map, "RAB / GSAB");
1092 GetCorrespondingRabGsabElementsKind(map->elements_kind()));
1115 bool UseFastFunctionNameLookup(Isolate* isolate, Map map) {
1116 DCHECK(map.IsJSFunctionMap());
1117 if (map.NumberOfOwnDescriptors() <
1121 DCHECK(!map.is_dictionary_map());
1124 auto descriptors = map.instance_descriptors(isolate);
1144 if (!UseFastFunctionNameLookup(isolate, function->map())) {