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

Side by Side Diff: src/bootstrapper.cc

Issue 7849017: Mechanical refactor to move ElementsKind type out of JSObject. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: latest changes Created 9 years, 3 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/arm/stub-cache-arm.cc ('k') | src/code-stubs.h » ('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 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 1049 matching lines...) Expand 10 before | Expand all | Expand 10 after
1060 ASSERT(result->HasFastProperties()); 1060 ASSERT(result->HasFastProperties());
1061 ASSERT(result->HasFastElements()); 1061 ASSERT(result->HasFastElements());
1062 #endif 1062 #endif
1063 } 1063 }
1064 1064
1065 { // --- aliased_arguments_boilerplate_ 1065 { // --- aliased_arguments_boilerplate_
1066 Handle<Map> old_map(global_context()->arguments_boilerplate()->map()); 1066 Handle<Map> old_map(global_context()->arguments_boilerplate()->map());
1067 Handle<Map> new_map = factory->CopyMapDropTransitions(old_map); 1067 Handle<Map> new_map = factory->CopyMapDropTransitions(old_map);
1068 new_map->set_pre_allocated_property_fields(2); 1068 new_map->set_pre_allocated_property_fields(2);
1069 Handle<JSObject> result = factory->NewJSObjectFromMap(new_map); 1069 Handle<JSObject> result = factory->NewJSObjectFromMap(new_map);
1070 new_map->set_elements_kind(JSObject::NON_STRICT_ARGUMENTS_ELEMENTS); 1070 new_map->set_elements_kind(NON_STRICT_ARGUMENTS_ELEMENTS);
1071 // Set up a well-formed parameter map to make assertions happy. 1071 // Set up a well-formed parameter map to make assertions happy.
1072 Handle<FixedArray> elements = factory->NewFixedArray(2); 1072 Handle<FixedArray> elements = factory->NewFixedArray(2);
1073 elements->set_map(heap->non_strict_arguments_elements_map()); 1073 elements->set_map(heap->non_strict_arguments_elements_map());
1074 Handle<FixedArray> array; 1074 Handle<FixedArray> array;
1075 array = factory->NewFixedArray(0); 1075 array = factory->NewFixedArray(0);
1076 elements->set(0, *array); 1076 elements->set(0, *array);
1077 array = factory->NewFixedArray(0); 1077 array = factory->NewFixedArray(0);
1078 elements->set(1, *array); 1078 elements->set(1, *array);
1079 result->set_elements(*elements); 1079 result->set_elements(*elements);
1080 global_context()->set_aliased_arguments_boilerplate(*result); 1080 global_context()->set_aliased_arguments_boilerplate(*result);
(...skipping 1144 matching lines...) Expand 10 before | Expand all | Expand 10 after
2225 return from + sizeof(NestingCounterType); 2225 return from + sizeof(NestingCounterType);
2226 } 2226 }
2227 2227
2228 2228
2229 // Called when the top-level V8 mutex is destroyed. 2229 // Called when the top-level V8 mutex is destroyed.
2230 void Bootstrapper::FreeThreadResources() { 2230 void Bootstrapper::FreeThreadResources() {
2231 ASSERT(!IsActive()); 2231 ASSERT(!IsActive());
2232 } 2232 }
2233 2233
2234 } } // namespace v8::internal 2234 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/stub-cache-arm.cc ('k') | src/code-stubs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698