Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(426)

Unified Diff: runtime/vm/object.cc

Issue 1858283002: Initial SIMDBC interpreter. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/object.h ('k') | runtime/vm/object_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.cc
diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
index c7ca37337d6584a8869dd008768a7466a80ef938..7f293d10fc99234ecdfe59c14a3cf7fedeaf007a 100644
--- a/runtime/vm/object.cc
+++ b/runtime/vm/object.cc
@@ -13825,6 +13825,7 @@ void Code::DisableDartCode() const {
void Code::DisableStubCode() const {
+#if !defined(TARGET_ARCH_DBC)
ASSERT(Thread::Current()->IsMutatorThread());
ASSERT(IsAllocationStubCode());
ASSERT(!IsDisabled());
@@ -13832,6 +13833,10 @@ void Code::DisableStubCode() const {
Code::Handle(StubCode::FixAllocationStubTarget_entry()->code());
ASSERT(new_code.instructions()->IsVMHeapObject());
SetActiveInstructions(new_code.instructions());
+#else
+ // DBC does not use allocation stubs.
+ UNIMPLEMENTED();
+#endif // !defined(TARGET_ARCH_DBC)
}
@@ -14970,7 +14975,9 @@ bool Instance::IsInstanceOf(const AbstractType& other,
Zone* zone = Thread::Current()->zone();
const Class& cls = Class::Handle(zone, clazz());
if (cls.IsClosureClass()) {
- if (other.IsObjectType() || other.IsDartFunctionType()) {
+ if (other.IsObjectType() ||
+ other.IsDartFunctionType() ||
+ other.IsDartClosureType()) {
return true;
}
Function& other_signature = Function::Handle(zone);
@@ -15757,6 +15764,13 @@ bool AbstractType::IsDartFunctionType() const {
}
+bool AbstractType::IsDartClosureType() const {
+ return !IsFunctionType() &&
+ HasResolvedTypeClass() &&
+ (type_class() == Isolate::Current()->object_store()->closure_class());
+}
+
+
bool AbstractType::TypeTest(TypeTestKind test_kind,
const AbstractType& other,
Error* bound_error,
« no previous file with comments | « runtime/vm/object.h ('k') | runtime/vm/object_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698