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

Side by Side Diff: src/objects-debug.cc

Issue 21065006: Replace HCheckPrototypeMaps by explicit map checks of constant values. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Prepare all HConstant js objects Created 7 years, 4 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/objects.h ('k') | src/objects-inl.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 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 348 matching lines...) Expand 10 before | Expand all | Expand 10 after
359 MapVerify(); 359 MapVerify();
360 CHECK(is_shared()); 360 CHECK(is_shared());
361 CHECK(instance_descriptors()->IsEmpty()); 361 CHECK(instance_descriptors()->IsEmpty());
362 CHECK_EQ(0, pre_allocated_property_fields()); 362 CHECK_EQ(0, pre_allocated_property_fields());
363 CHECK_EQ(0, unused_property_fields()); 363 CHECK_EQ(0, unused_property_fields());
364 CHECK_EQ(StaticVisitorBase::GetVisitorId(instance_type(), instance_size()), 364 CHECK_EQ(StaticVisitorBase::GetVisitorId(instance_type(), instance_size()),
365 visitor_id()); 365 visitor_id());
366 } 366 }
367 367
368 368
369 void Map::VerifyOmittedPrototypeChecks() { 369 void Map::VerifyOmittedMapChecks() {
370 if (!FLAG_omit_prototype_checks_for_leaf_maps) return; 370 if (!FLAG_omit_map_checks_for_leaf_maps) return;
371 if (HasTransitionArray() || is_dictionary_map()) { 371 if (!is_stable() ||
372 is_deprecated() ||
373 HasTransitionArray() ||
374 is_dictionary_map()) {
372 CHECK_EQ(0, dependent_code()->number_of_entries( 375 CHECK_EQ(0, dependent_code()->number_of_entries(
373 DependentCode::kPrototypeCheckGroup)); 376 DependentCode::kPrototypeCheckGroup));
374 } 377 }
375 } 378 }
376 379
377 380
378 void CodeCache::CodeCacheVerify() { 381 void CodeCache::CodeCacheVerify() {
379 VerifyHeapPointer(default_cache()); 382 VerifyHeapPointer(default_cache());
380 VerifyHeapPointer(normal_type_cache()); 383 VerifyHeapPointer(normal_type_cache());
381 CHECK(default_cache()->IsFixedArray()); 384 CHECK(default_cache()->IsFixedArray());
(...skipping 787 matching lines...) Expand 10 before | Expand all | Expand 10 after
1169 for (int i = 0; i < number_of_transitions(); ++i) { 1172 for (int i = 0; i < number_of_transitions(); ++i) {
1170 if (!CheckOneBackPointer(current_map, GetTarget(i))) return false; 1173 if (!CheckOneBackPointer(current_map, GetTarget(i))) return false;
1171 } 1174 }
1172 return true; 1175 return true;
1173 } 1176 }
1174 1177
1175 1178
1176 #endif // DEBUG 1179 #endif // DEBUG
1177 1180
1178 } } // namespace v8::internal 1181 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/objects.h ('k') | src/objects-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698