Index: src/hydrogen.cc |
diff --git a/src/hydrogen.cc b/src/hydrogen.cc |
index 0ca78f3da9a53b6fd44de6feb4141f2969ca05bb..4389bfe78ab391c44a24a8ab36874e57968046cf 100644 |
--- a/src/hydrogen.cc |
+++ b/src/hydrogen.cc |
@@ -8655,6 +8655,11 @@ bool HOptimizedGraphBuilder::TryInlineApiCall(Handle<JSFunction> function, |
CallOptimization optimization(function); |
if (!optimization.is_simple_api_call()) return false; |
Handle<Map> holder_map; |
+ for (int i = 0; i < receiver_maps->length(); ++i) { |
+ auto map = receiver_maps->at(i); |
+ // Don't inline calls to receivers requiring accesschecks. |
+ if (map->is_access_check_needed()) return false; |
+ } |
if (call_type == kCallApiFunction) { |
// Cannot embed a direct reference to the global proxy map |
// as it maybe dropped on deserialization. |