Chromium Code Reviews| Index: runtime/vm/precompiler.cc |
| diff --git a/runtime/vm/precompiler.cc b/runtime/vm/precompiler.cc |
| index 0dd3b18cd5469fa5206f833d8b484376500c3b6e..24754f58eff8a748e2a575fa7801828b20f8bfd7 100644 |
| --- a/runtime/vm/precompiler.cc |
| +++ b/runtime/vm/precompiler.cc |
| @@ -245,6 +245,7 @@ bool TypeRangeCache::InstanceOfHasClassRange(const AbstractType& type, |
| if (!type.IsInstantiated()) return false; |
| if (type.IsFunctionType()) return false; |
| + if (type.IsDartFunctionType()) return false; |
| Zone* zone = thread_->zone(); |
| const TypeArguments& type_arguments = |
| @@ -271,6 +272,9 @@ bool TypeRangeCache::InstanceOfHasClassRange(const AbstractType& type, |
| Class& cls = Class::Handle(zone); |
| AbstractType& cls_type = AbstractType::Handle(zone); |
| for (intptr_t cid = kInstanceCid; cid < table->NumCids(); cid++) { |
| + StackZone stack_zone(thread_); |
|
rmacnak
2017/01/11 19:09:01
Add a note that we might allocate a lot of handles
Florian Schneider
2017/01/11 19:11:14
Done.
|
| + HANDLESCOPE(thread_); |
| + |
| if (!table->HasValidClassAt(cid)) continue; |
| if (cid == kVoidCid) continue; |
| if (cid == kDynamicCid) continue; |
| @@ -281,7 +285,7 @@ bool TypeRangeCache::InstanceOfHasClassRange(const AbstractType& type, |
| if (cls.IsTopLevel()) continue; |
| cls_type = cls.RareType(); |
| - if (cls_type.IsSubtypeOf(type, NULL, NULL, Heap::kOld)) { |
| + if (cls_type.IsSubtypeOf(type, NULL, NULL, Heap::kNew)) { |
| last_matching_cid = cid; |
| if (*lower_limit == -1) { |
| // Found beginning of range. |