Home | History | Annotate | Download | only in cctest

Lines Matching refs:table

45 static void TestHashMap(Handle<HashMap> table) {
51 table = HashMap::Put(table, a, b);
52 CHECK_EQ(table->NumberOfElements(), 1);
53 CHECK_EQ(table->Lookup(a), *b);
55 CHECK_EQ(table->Lookup(b), CcTest::heap()->the_hole_value());
59 CHECK_EQ(table->NumberOfElements(), 1);
60 CHECK_EQ(table->Lookup(a), *b);
61 CHECK_EQ(table->Lookup(b), CcTest::heap()->the_hole_value());
64 table = HashMap::Put(table, a, factory->NewJSArray(13));
65 CHECK_EQ(table->NumberOfElements(), 1);
66 CHECK_NE(table->Lookup(a), *b);
70 table = HashMap::Remove(table, a, &was_present);
72 CHECK_EQ(table->NumberOfElements(), 0);
73 CHECK_EQ(table->Lookup(a), CcTest::heap()->the_hole_value());
80 table = HashMap::Put(table, key, value);
81 CHECK_EQ(table->NumberOfElements(), i + 1);
82 CHECK_NE(table->FindEntry(key), HashMap::kNotFound);
83 CHECK_EQ(table->Lookup(key), *value);
92 CHECK_EQ(table->FindEntry(key), HashMap::kNotFound);
93 CHECK_EQ(table->Lookup(key), CcTest::heap()->the_hole_value());
101 CHECK_EQ(table->Lookup(key), CcTest::heap()->the_hole_value());
139 // Test almost filled table.
141 Handle<ObjectHashTable> table = ObjectHashTable::New(isolate, 100);
142 ObjectHashTableTest* t = reinterpret_cast<ObjectHashTableTest*>(*table);
152 // Test half-filled table.
154 Handle<ObjectHashTable> table = ObjectHashTable::New(isolate, 100);
155 ObjectHashTableTest* t = reinterpret_cast<ObjectHashTableTest*>(*table);
170 static void TestHashSetCausesGC(Handle<HashSet> table) {
177 // Force allocation of hash table backing store for hidden properties.
189 CHECK(!table->Contains(key));
194 table = HashSet::Remove(table, key, &was_present);
199 table = HashSet::Add(table, key);
216 static void TestHashMapCausesGC(Handle<HashMap> table) {
223 // Force allocation of hash table backing store for hidden properties.
234 CHECK(table->Lookup(key)->IsTheHole());
238 HashMap::Put(table, key, key);