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

Side by Side Diff: src/heap-snapshot-generator.cc

Issue 1307963002: Native context: alpha sort slots and remove boilerplate. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: rename Created 5 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
« no previous file with comments | « src/date.js ('k') | src/json.js » ('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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/heap-snapshot-generator.h" 5 #include "src/heap-snapshot-generator.h"
6 6
7 #include "src/allocation-tracker.h" 7 #include "src/allocation-tracker.h"
8 #include "src/code-stubs.h" 8 #include "src/code-stubs.h"
9 #include "src/conversions.h" 9 #include "src/conversions.h"
10 #include "src/debug/debug.h" 10 #include "src/debug/debug.h"
(...skipping 1247 matching lines...) Expand 10 before | Expand all | Expand 10 after
1258 FixedArray::OffsetOfElementAt(Context::index)); \ 1258 FixedArray::OffsetOfElementAt(Context::index)); \
1259 } 1259 }
1260 EXTRACT_CONTEXT_FIELD(CLOSURE_INDEX, JSFunction, closure); 1260 EXTRACT_CONTEXT_FIELD(CLOSURE_INDEX, JSFunction, closure);
1261 EXTRACT_CONTEXT_FIELD(PREVIOUS_INDEX, Context, previous); 1261 EXTRACT_CONTEXT_FIELD(PREVIOUS_INDEX, Context, previous);
1262 EXTRACT_CONTEXT_FIELD(EXTENSION_INDEX, Object, extension); 1262 EXTRACT_CONTEXT_FIELD(EXTENSION_INDEX, Object, extension);
1263 EXTRACT_CONTEXT_FIELD(GLOBAL_OBJECT_INDEX, GlobalObject, global); 1263 EXTRACT_CONTEXT_FIELD(GLOBAL_OBJECT_INDEX, GlobalObject, global);
1264 if (context->IsNativeContext()) { 1264 if (context->IsNativeContext()) {
1265 TagObject(context->normalized_map_cache(), "(context norm. map cache)"); 1265 TagObject(context->normalized_map_cache(), "(context norm. map cache)");
1266 TagObject(context->runtime_context(), "(runtime context)"); 1266 TagObject(context->runtime_context(), "(runtime context)");
1267 TagObject(context->embedder_data(), "(context data)"); 1267 TagObject(context->embedder_data(), "(context data)");
1268 NATIVE_CONTEXT_FIELDS(EXTRACT_CONTEXT_FIELD); 1268 NATIVE_CONTEXT_FIELDS(EXTRACT_CONTEXT_FIELD)
1269 EXTRACT_CONTEXT_FIELD(OPTIMIZED_FUNCTIONS_LIST, unused, 1269 EXTRACT_CONTEXT_FIELD(OPTIMIZED_FUNCTIONS_LIST, unused,
1270 optimized_functions_list); 1270 optimized_functions_list);
1271 EXTRACT_CONTEXT_FIELD(OPTIMIZED_CODE_LIST, unused, optimized_code_list); 1271 EXTRACT_CONTEXT_FIELD(OPTIMIZED_CODE_LIST, unused, optimized_code_list);
1272 EXTRACT_CONTEXT_FIELD(DEOPTIMIZED_CODE_LIST, unused, deoptimized_code_list); 1272 EXTRACT_CONTEXT_FIELD(DEOPTIMIZED_CODE_LIST, unused, deoptimized_code_list);
1273 EXTRACT_CONTEXT_FIELD(NEXT_CONTEXT_LINK, unused, next_context_link); 1273 EXTRACT_CONTEXT_FIELD(NEXT_CONTEXT_LINK, unused, next_context_link);
1274 #undef EXTRACT_CONTEXT_FIELD 1274 #undef EXTRACT_CONTEXT_FIELD
1275 STATIC_ASSERT(Context::OPTIMIZED_FUNCTIONS_LIST == 1275 STATIC_ASSERT(Context::OPTIMIZED_FUNCTIONS_LIST ==
1276 Context::FIRST_WEAK_SLOT); 1276 Context::FIRST_WEAK_SLOT);
1277 STATIC_ASSERT(Context::NEXT_CONTEXT_LINK + 1 == 1277 STATIC_ASSERT(Context::NEXT_CONTEXT_LINK + 1 ==
1278 Context::NATIVE_CONTEXT_SLOTS); 1278 Context::NATIVE_CONTEXT_SLOTS);
(...skipping 1893 matching lines...) Expand 10 before | Expand all | Expand 10 after
3172 for (int i = 1; i < sorted_strings.length(); ++i) { 3172 for (int i = 1; i < sorted_strings.length(); ++i) {
3173 writer_->AddCharacter(','); 3173 writer_->AddCharacter(',');
3174 SerializeString(sorted_strings[i]); 3174 SerializeString(sorted_strings[i]);
3175 if (writer_->aborted()) return; 3175 if (writer_->aborted()) return;
3176 } 3176 }
3177 } 3177 }
3178 3178
3179 3179
3180 } // namespace internal 3180 } // namespace internal
3181 } // namespace v8 3181 } // namespace v8
OLDNEW
« no previous file with comments | « src/date.js ('k') | src/json.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698