Commit ea9ee866 authored by Georg Neis's avatar Georg Neis Committed by Commit Bot

Add some debug checks and fix some comments.

Change-Id: I6f0f003b09fea49718eadc59cf35bdb346c585d1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2536636
Commit-Queue: Georg Neis <neis@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Auto-Submit: Georg Neis <neis@chromium.org>
Reviewed-by: 's avatarDominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71178}
parent 0f5ad735
......@@ -287,6 +287,7 @@ uint32_t NameDictionaryShape::HashForObject(ReadOnlyRoots roots, Object other) {
}
bool GlobalDictionaryShape::IsMatch(Handle<Name> key, Object other) {
DCHECK(key->IsUniqueName());
DCHECK(PropertyCell::cast(other).name().IsUniqueName());
return *key == PropertyCell::cast(other).name();
}
......
......@@ -60,8 +60,9 @@ class EXPORT_TEMPLATE_DECLARE(V8_EXPORT_PRIVATE) Dictionary
// Returns the key (slow).
Object SlowReverseLookup(Object value);
// Sets the entry to (key, value) pair.
inline void ClearEntry(InternalIndex entry);
// Sets the entry to (key, value) pair.
inline void SetEntry(InternalIndex entry, Object key, Object value,
PropertyDetails details);
......
......@@ -142,6 +142,7 @@ template <typename Derived, typename Shape>
InternalIndex HashTable<Derived, Shape>::FindEntry(IsolateRoot isolate,
ReadOnlyRoots roots, Key key,
int32_t hash) {
DisallowGarbageCollection no_gc;
uint32_t capacity = Capacity();
uint32_t count = 1;
Object undefined = roots.undefined_value();
......
......@@ -177,10 +177,9 @@ using MapHandles = std::vector<Handle<Map>>;
// +---------------+------------------------------------------------+
// | TaggedPointer | [instance_descriptors] |
// +****************************************************************+
// ! TaggedPointer ! [layout_descriptors] !
// ! TaggedPointer ! [layout_descriptor] !
// ! ! Field is only present if compile-time flag !
// ! ! FLAG_unbox_double_fields is enabled !
// ! ! (basically on 64 bit architectures) !
// +****************************************************************+
// | TaggedPointer | [dependent_code] |
// +---------------+------------------------------------------------+
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment