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

Unified Diff: runtime/vm/object.cc

Issue 1863733004: Fixes crashes in inliner: do not inline if icdata was cleared. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: bb 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/weak_code.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 a0d5f2defe1fa87b6f7f8ec9196a0182eacaa26e..44e9d23312d593d64b356ef300bad1de9e43d571 100644
--- a/runtime/vm/object.cc
+++ b/runtime/vm/object.cc
@@ -9487,6 +9487,7 @@ bool Library::LookupResolvedNamesCache(const String& name,
// the name does not resolve to anything in this library scope.
void Library::AddToResolvedNamesCache(const String& name,
const Object& obj) const {
+ ASSERT(!Compiler::IsBackgroundCompilation());
if (!FLAG_use_lib_cache) {
return;
}
@@ -9545,6 +9546,7 @@ void Library::GrowDictionary(const Array& dict, intptr_t dict_size) const {
void Library::AddObject(const Object& obj, const String& name) const {
+ ASSERT(!Compiler::IsBackgroundCompilation());
ASSERT(obj.IsClass() ||
obj.IsFunction() ||
obj.IsField() ||
@@ -9651,6 +9653,7 @@ RawObject* Library::LookupEntry(const String& name, intptr_t *index) const {
void Library::ReplaceObject(const Object& obj, const String& name) const {
+ ASSERT(!Compiler::IsBackgroundCompilation());
ASSERT(obj.IsClass() || obj.IsFunction() || obj.IsField());
ASSERT(LookupLocalObject(name) != Object::null());
@@ -9663,6 +9666,7 @@ void Library::ReplaceObject(const Object& obj, const String& name) const {
bool Library::RemoveObject(const Object& obj, const String& name) const {
+ ASSERT(!Compiler::IsBackgroundCompilation());
Object& entry = Object::Handle();
intptr_t index;
@@ -9708,6 +9712,7 @@ bool Library::RemoveObject(const Object& obj, const String& name) const {
void Library::AddClass(const Class& cls) const {
+ ASSERT(!Compiler::IsBackgroundCompilation());
const String& class_name = String::Handle(cls.Name());
AddObject(cls, class_name);
// Link class to this library.
@@ -9715,6 +9720,7 @@ void Library::AddClass(const Class& cls) const {
InvalidateResolvedName(class_name);
}
+
static void AddScriptIfUnique(const GrowableObjectArray& scripts,
const Script& candidate) {
if (candidate.IsNull()) {
@@ -9733,6 +9739,7 @@ static void AddScriptIfUnique(const GrowableObjectArray& scripts,
scripts.Add(candidate);
}
+
RawArray* Library::LoadedScripts() const {
// We compute the list of loaded scripts lazily. The result is
// cached in loaded_scripts_.
« no previous file with comments | « runtime/vm/object.h ('k') | runtime/vm/weak_code.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698