| Index: runtime/vm/isolate_reload.cc
|
| diff --git a/runtime/vm/isolate_reload.cc b/runtime/vm/isolate_reload.cc
|
| index 15aaf2920aa5b1b66cbe38dde6eaeda311330593..d42bb25b61e02f43af53263e9ac2d73bbeb9e9b7 100644
|
| --- a/runtime/vm/isolate_reload.cc
|
| +++ b/runtime/vm/isolate_reload.cc
|
| @@ -184,7 +184,6 @@ IsolateReloadContext::IsolateReloadContext(Isolate* isolate, bool test_mode)
|
| script_uri_(String::null()),
|
| error_(Error::null()),
|
| clean_scripts_set_storage_(Array::null()),
|
| - compile_time_constants_(Array::null()),
|
| old_classes_set_storage_(Array::null()),
|
| class_map_storage_(Array::null()),
|
| old_libraries_set_storage_(Array::null()),
|
| @@ -507,55 +506,6 @@ void IsolateReloadContext::BuildCleanScriptSet() {
|
| }
|
|
|
|
|
| -void IsolateReloadContext::FilterCompileTimeConstants() {
|
| - // Save the compile time constants array.
|
| - compile_time_constants_ = I->object_store()->compile_time_constants();
|
| - // Clear the compile time constants array. This will be repopulated
|
| - // in the loop below.
|
| - I->object_store()->set_compile_time_constants(Array::Handle());
|
| -
|
| - if (compile_time_constants_ == Array::null()) {
|
| - // Nothing to do.
|
| - return;
|
| - }
|
| -
|
| - // Iterate over the saved compile time constants map.
|
| - ConstantsMap old_constants(compile_time_constants_);
|
| - ConstantsMap::Iterator it(&old_constants);
|
| -
|
| - Array& key = Array::Handle();
|
| - String& url = String::Handle();
|
| - Smi& token_pos = Smi::Handle();
|
| - Instance& value = Instance::Handle();
|
| -
|
| - // We filter the compile time constants map so that after it only contains
|
| - // constants from scripts contained in this set.
|
| - UnorderedHashSet<ScriptUrlSetTraits>
|
| - clean_scripts_set(clean_scripts_set_storage_);
|
| -
|
| - while (it.MoveNext()) {
|
| - const intptr_t entry = it.Current();
|
| - ASSERT(entry != -1);
|
| - key = Array::RawCast(old_constants.GetKey(entry));
|
| - ASSERT(!key.IsNull());
|
| - url = String::RawCast(key.At(0));
|
| - ASSERT(!url.IsNull());
|
| - if (clean_scripts_set.ContainsKey(url)) {
|
| - // We've found a cached constant from a clean script, add it to the
|
| - // compile time constants map again.
|
| - token_pos = Smi::RawCast(key.At(1));
|
| - TokenPosition tp(token_pos.Value());
|
| - // Use ^= because this might be null.
|
| - value ^= old_constants.GetPayload(entry, 0);
|
| - Parser::InsertCachedConstantValue(url, tp, value);
|
| - }
|
| - }
|
| -
|
| - old_constants.Release();
|
| - clean_scripts_set.Release();
|
| -}
|
| -
|
| -
|
| // While reloading everything we do must be reversible so that we can abort
|
| // safely if the reload fails. This function stashes things to the side and
|
| // prepares the isolate for the reload attempt.
|
| @@ -564,7 +514,6 @@ void IsolateReloadContext::Checkpoint() {
|
| CheckpointClasses();
|
| CheckpointLibraries();
|
| BuildCleanScriptSet();
|
| - FilterCompileTimeConstants();
|
| }
|
|
|
|
|
| @@ -614,8 +563,6 @@ void IsolateReloadContext::RollbackLibraries() {
|
|
|
|
|
| void IsolateReloadContext::Rollback() {
|
| - I->object_store()->set_compile_time_constants(
|
| - Array::Handle(compile_time_constants_));
|
| RollbackClasses();
|
| RollbackLibraries();
|
| }
|
|
|