Index: src/arm64/stub-cache-arm64.cc |
diff --git a/src/arm64/stub-cache-arm64.cc b/src/arm64/stub-cache-arm64.cc |
index 1bd2ac8fed959bbf7fd1595992ae5a52955a8dd6..9c07c0a06ddab645619dc2e025c91aa012f92e78 100644 |
--- a/src/arm64/stub-cache-arm64.cc |
+++ b/src/arm64/stub-cache-arm64.cc |
@@ -691,8 +691,8 @@ Register PropertyHandlerCompiler::CheckPrototypes( |
prototype = handle(JSObject::cast(current_map->prototype())); |
if (current_map->is_dictionary_map() && |
- !current_map->IsJSGlobalObjectMap() && |
- !current_map->IsJSGlobalProxyMap()) { |
+ !current_map->IsJSGlobalObjectMap()) { |
+ DCHECK(!current_map->IsJSGlobalProxyMap()); // Proxy maps are fast. |
if (!name->IsUniqueName()) { |
DCHECK(name->IsString()); |
name = factory()->InternalizeString(Handle<String>::cast(name)); |
@@ -724,6 +724,9 @@ Register PropertyHandlerCompiler::CheckPrototypes( |
// Check access rights to the global object. This has to happen after |
// the map check so that we know that the object is actually a global |
// object. |
+ // This allows us to install generated handlers for accesses to the |
+ // global proxy (as opposed to using slow ICs). See corresponding code |
+ // in LookupForRead(). |
if (current_map->IsJSGlobalProxyMap()) { |
UseScratchRegisterScope temps(masm()); |
__ CheckAccessGlobalProxy(reg, scratch2, temps.AcquireX(), miss); |