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

Unified Diff: src/factory.cc

Issue 1226203011: Remove unused byte from Map::instance_sizes field. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Ported to all architectures. Created 5 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/factory.h ('k') | src/heap/heap.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/factory.cc
diff --git a/src/factory.cc b/src/factory.cc
index 2b79a5bf8f25a74a8ac37a35efa75fe7427ea86e..f8154180f0cbacccc32a3917b7e16fba7e4552e6 100644
--- a/src/factory.cc
+++ b/src/factory.cc
@@ -1596,14 +1596,12 @@ Handle<GlobalObject> Factory::NewGlobalObject(Handle<JSFunction> constructor) {
Handle<JSObject> Factory::NewJSObjectFromMap(
Handle<Map> map,
PretenureFlag pretenure,
- bool alloc_props,
Handle<AllocationSite> allocation_site) {
CALL_HEAP_FUNCTION(
isolate(),
isolate()->heap()->AllocateJSObjectFromMap(
*map,
pretenure,
- alloc_props,
allocation_site.is_null() ? NULL : *allocation_site),
JSObject);
}
@@ -2002,8 +2000,7 @@ void Factory::ReinitializeJSProxy(Handle<JSProxy> proxy, InstanceType type,
DCHECK(size_difference >= 0);
// Allocate the backing storage for the properties.
- int prop_size = map->InitialPropertiesLength();
- Handle<FixedArray> properties = NewFixedArray(prop_size, TENURED);
+ Handle<FixedArray> properties = empty_fixed_array();
Heap* heap = isolate()->heap();
MaybeHandle<SharedFunctionInfo> shared;
@@ -2056,9 +2053,9 @@ Handle<JSGlobalProxy> Factory::NewUninitializedJSGlobalProxy() {
Handle<Map> map = NewMap(JS_GLOBAL_PROXY_TYPE, JSGlobalProxy::kSize);
// Maintain invariant expected from any JSGlobalProxy.
map->set_is_access_check_needed(true);
- CALL_HEAP_FUNCTION(isolate(), isolate()->heap()->AllocateJSObjectFromMap(
- *map, NOT_TENURED, false),
- JSGlobalProxy);
+ CALL_HEAP_FUNCTION(
+ isolate(), isolate()->heap()->AllocateJSObjectFromMap(*map, NOT_TENURED),
+ JSGlobalProxy);
}
@@ -2076,8 +2073,7 @@ void Factory::ReinitializeJSGlobalProxy(Handle<JSGlobalProxy> object,
DCHECK(map->instance_type() == object->map()->instance_type());
// Allocate the backing storage for the properties.
- int prop_size = map->InitialPropertiesLength();
- Handle<FixedArray> properties = NewFixedArray(prop_size, TENURED);
+ Handle<FixedArray> properties = empty_fixed_array();
// In order to keep heap in consistent state there must be no allocations
// before object re-initialization is finished.
« no previous file with comments | « src/factory.h ('k') | src/heap/heap.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698