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.cc

Issue 9174023: Split NumberDictionary into a randomly seeded and an unseeded (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 8 years, 11 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/heap.h ('k') | src/ia32/macro-assembler-ia32.cc » ('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 2445 matching lines...) Expand 10 before | Expand all | Expand 10 after
2456 2456
2457 // Allocate the foreign for __proto__. 2457 // Allocate the foreign for __proto__.
2458 { MaybeObject* maybe_obj = 2458 { MaybeObject* maybe_obj =
2459 AllocateForeign((Address) &Accessors::ObjectPrototype); 2459 AllocateForeign((Address) &Accessors::ObjectPrototype);
2460 if (!maybe_obj->ToObject(&obj)) return false; 2460 if (!maybe_obj->ToObject(&obj)) return false;
2461 } 2461 }
2462 set_prototype_accessors(Foreign::cast(obj)); 2462 set_prototype_accessors(Foreign::cast(obj));
2463 2463
2464 // Allocate the code_stubs dictionary. The initial size is set to avoid 2464 // Allocate the code_stubs dictionary. The initial size is set to avoid
2465 // expanding the dictionary during bootstrapping. 2465 // expanding the dictionary during bootstrapping.
2466 { MaybeObject* maybe_obj = NumberDictionary::Allocate(128); 2466 { MaybeObject* maybe_obj = UnseededNumberDictionary::Allocate(128);
2467 if (!maybe_obj->ToObject(&obj)) return false; 2467 if (!maybe_obj->ToObject(&obj)) return false;
2468 } 2468 }
2469 set_code_stubs(NumberDictionary::cast(obj)); 2469 set_code_stubs(UnseededNumberDictionary::cast(obj));
2470 2470
2471 2471
2472 // Allocate the non_monomorphic_cache used in stub-cache.cc. The initial size 2472 // Allocate the non_monomorphic_cache used in stub-cache.cc. The initial size
2473 // is set to avoid expanding the dictionary during bootstrapping. 2473 // is set to avoid expanding the dictionary during bootstrapping.
2474 { MaybeObject* maybe_obj = NumberDictionary::Allocate(64); 2474 { MaybeObject* maybe_obj = UnseededNumberDictionary::Allocate(64);
2475 if (!maybe_obj->ToObject(&obj)) return false; 2475 if (!maybe_obj->ToObject(&obj)) return false;
2476 } 2476 }
2477 set_non_monomorphic_cache(NumberDictionary::cast(obj)); 2477 set_non_monomorphic_cache(UnseededNumberDictionary::cast(obj));
2478 2478
2479 { MaybeObject* maybe_obj = AllocatePolymorphicCodeCache(); 2479 { MaybeObject* maybe_obj = AllocatePolymorphicCodeCache();
2480 if (!maybe_obj->ToObject(&obj)) return false; 2480 if (!maybe_obj->ToObject(&obj)) return false;
2481 } 2481 }
2482 set_polymorphic_code_cache(PolymorphicCodeCache::cast(obj)); 2482 set_polymorphic_code_cache(PolymorphicCodeCache::cast(obj));
2483 2483
2484 set_instanceof_cache_function(Smi::FromInt(0)); 2484 set_instanceof_cache_function(Smi::FromInt(0));
2485 set_instanceof_cache_map(Smi::FromInt(0)); 2485 set_instanceof_cache_map(Smi::FromInt(0));
2486 set_instanceof_cache_answer(Smi::FromInt(0)); 2486 set_instanceof_cache_answer(Smi::FromInt(0));
2487 2487
(...skipping 4166 matching lines...) Expand 10 before | Expand all | Expand 10 after
6654 isolate_->heap()->store_buffer()->Compact(); 6654 isolate_->heap()->store_buffer()->Compact();
6655 isolate_->heap()->store_buffer()->Filter(MemoryChunk::ABOUT_TO_BE_FREED); 6655 isolate_->heap()->store_buffer()->Filter(MemoryChunk::ABOUT_TO_BE_FREED);
6656 for (chunk = chunks_queued_for_free_; chunk != NULL; chunk = next) { 6656 for (chunk = chunks_queued_for_free_; chunk != NULL; chunk = next) {
6657 next = chunk->next_chunk(); 6657 next = chunk->next_chunk();
6658 isolate_->memory_allocator()->Free(chunk); 6658 isolate_->memory_allocator()->Free(chunk);
6659 } 6659 }
6660 chunks_queued_for_free_ = NULL; 6660 chunks_queued_for_free_ = NULL;
6661 } 6661 }
6662 6662
6663 } } // namespace v8::internal 6663 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/heap.h ('k') | src/ia32/macro-assembler-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698