Index: src/stub-cache.cc |
diff --git a/src/stub-cache.cc b/src/stub-cache.cc |
index 4bbfe176875852072578e068ef96663b56a4ce83..650422c14cf47ab2e1a80cc394ceed1c37cb33ac 100644 |
--- a/src/stub-cache.cc |
+++ b/src/stub-cache.cc |
@@ -45,26 +45,13 @@ namespace internal { |
StubCache::StubCache(Isolate* isolate) : isolate_(isolate) { |
ASSERT(isolate == Isolate::Current()); |
- memset(primary_, 0, sizeof(primary_[0]) * StubCache::kPrimaryTableSize); |
- memset(secondary_, 0, sizeof(secondary_[0]) * StubCache::kSecondaryTableSize); |
} |
-void StubCache::Initialize(bool create_heap_objects) { |
+void StubCache::Initialize() { |
ASSERT(IsPowerOf2(kPrimaryTableSize)); |
ASSERT(IsPowerOf2(kSecondaryTableSize)); |
- if (create_heap_objects) { |
- HandleScope scope; |
- Code* empty = isolate_->builtins()->builtin(Builtins::kIllegal); |
- for (int i = 0; i < kPrimaryTableSize; i++) { |
- primary_[i].key = heap()->empty_string(); |
- primary_[i].value = empty; |
- } |
- for (int j = 0; j < kSecondaryTableSize; j++) { |
- secondary_[j].key = heap()->empty_string(); |
- secondary_[j].value = empty; |
- } |
- } |
+ Clear(); |
} |