Reviewers: Jakob,
Message:
PTAL
Description:
Also skip when the target is the global object
BUG=
Please review this at https://codereview.chromium.org/961723002/
Base URL: https://chromium.googlesource.com/v8/v8.git@master
Affected files (+8, -4 lines):
M src/ic/arm/handler-compiler-arm.cc
M src/ic/arm64/handler-compiler-arm64.cc
M src/ic/ia32/handler-compiler-ia32.cc
M src/ic/x64/handler-compiler-x64.cc
Index: src/ic/arm/handler-compiler-arm.cc
diff --git a/src/ic/arm/handler-compiler-arm.cc
b/src/ic/arm/handler-compiler-arm.cc
index
a4c06079051c48cf63f453657d5f34e7f6131a45..78dbfa452cab21c1ed30879e0294bc46ab6b9191
100644
--- a/src/ic/arm/handler-compiler-arm.cc
+++ b/src/ic/arm/handler-compiler-arm.cc
@@ -497,7 +497,8 @@ Register PropertyHandlerCompiler::CheckPrototypes(
// Log the check depth.
LOG(isolate(), IntEvent("check-maps-depth", depth + 1));
- if (depth != 0 || check == CHECK_ALL_MAPS) {
+ if (!current_map->IsJSGlobalObjectMap() &&
+ (depth != 0 || check == CHECK_ALL_MAPS)) {
// Check the holder map.
__ ldr(scratch1, FieldMemOperand(reg, HeapObject::kMapOffset));
Handle<WeakCell> cell = Map::WeakCellForMap(current_map);
Index: src/ic/arm64/handler-compiler-arm64.cc
diff --git a/src/ic/arm64/handler-compiler-arm64.cc
b/src/ic/arm64/handler-compiler-arm64.cc
index
53519179f269d54e7d307bbc9ce2189d4320931c..db55e23b49ed7da99ab12a93938e201a10ff253d
100644
--- a/src/ic/arm64/handler-compiler-arm64.cc
+++ b/src/ic/arm64/handler-compiler-arm64.cc
@@ -548,7 +548,8 @@ Register PropertyHandlerCompiler::CheckPrototypes(
LOG(isolate(), IntEvent("check-maps-depth", depth + 1));
// Check the holder map.
- if (depth != 0 || check == CHECK_ALL_MAPS) {
+ if (!current_map->IsJSGlobalObjectMap() &&
+ (depth != 0 || check == CHECK_ALL_MAPS)) {
// Check the holder map.
__ Ldr(scratch1, FieldMemOperand(reg, HeapObject::kMapOffset));
Handle<WeakCell> cell = Map::WeakCellForMap(current_map);
Index: src/ic/ia32/handler-compiler-ia32.cc
diff --git a/src/ic/ia32/handler-compiler-ia32.cc
b/src/ic/ia32/handler-compiler-ia32.cc
index
7bb426c61e559d847f11707a6d5439a04f04193c..850bfbd3ea0b08838bec69274ce2773e887c2c49
100644
--- a/src/ic/ia32/handler-compiler-ia32.cc
+++ b/src/ic/ia32/handler-compiler-ia32.cc
@@ -498,7 +498,8 @@ Register PropertyHandlerCompiler::CheckPrototypes(
// Log the check depth.
LOG(isolate(), IntEvent("check-maps-depth", depth + 1));
- if (depth != 0 || check == CHECK_ALL_MAPS) {
+ if (!current_map->IsJSGlobalObjectMap() &&
+ (depth != 0 || check == CHECK_ALL_MAPS)) {
// Check the holder map.
__ mov(scratch1, FieldOperand(reg, HeapObject::kMapOffset));
Handle<WeakCell> cell = Map::WeakCellForMap(current_map);
Index: src/ic/x64/handler-compiler-x64.cc
diff --git a/src/ic/x64/handler-compiler-x64.cc
b/src/ic/x64/handler-compiler-x64.cc
index
4b066f2d4291e2d2f3f48104c55c515add11ff77..26fd0716643978345afba50216096ccdda825432
100644
--- a/src/ic/x64/handler-compiler-x64.cc
+++ b/src/ic/x64/handler-compiler-x64.cc
@@ -500,7 +500,8 @@ Register PropertyHandlerCompiler::CheckPrototypes(
// Log the check depth.
LOG(isolate(), IntEvent("check-maps-depth", depth + 1));
- if (depth != 0 || check == CHECK_ALL_MAPS) {
+ if (!current_map->IsJSGlobalObjectMap() &&
+ (depth != 0 || check == CHECK_ALL_MAPS)) {
__ movp(scratch1, FieldOperand(reg, HeapObject::kMapOffset));
Handle<WeakCell> cell = Map::WeakCellForMap(current_map);
__ CmpWeakValue(scratch1, cell, scratch2);
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.