@@ -43,7 +43,6 @@ using v8::Isolate; |
43 | 43 | using v8::Local; |
44 | 44 | using v8::Object; |
45 | 45 | using v8::ObjectTemplate; |
46 | | -using v8::ScriptCompiler; |
47 | 46 | using v8::SnapshotCreator; |
48 | 47 | using v8::StartupData; |
49 | 48 | using v8::String; |
@@ -542,7 +541,6 @@ SnapshotMetadata SnapshotDeserializer::Read() { |
542 | 541 | result.node_version = ReadString(); |
543 | 542 | result.node_arch = ReadString(); |
544 | 543 | result.node_platform = ReadString(); |
545 | | - result.v8_cache_version_tag = ReadArithmetic<uint32_t>(); |
546 | 544 | result.flags = static_cast<SnapshotFlags>(ReadArithmetic<uint32_t>()); |
547 | 545 |
|
548 | 546 | if (is_debug) { |
@@ -570,9 +568,6 @@ size_t SnapshotSerializer::Write(const SnapshotMetadata& data) { |
570 | 568 | written_total += WriteString(data.node_arch); |
571 | 569 | Debug("Write Node.js platform %s\n", data.node_platform); |
572 | 570 | written_total += WriteString(data.node_platform); |
573 | | - Debug("Write V8 cached data version tag %" PRIx32 "\n", |
574 | | - data.v8_cache_version_tag); |
575 | | - written_total += WriteArithmetic<uint32_t>(data.v8_cache_version_tag); |
576 | 571 | Debug("Write snapshot flags %" PRIx32 "\n", |
577 | 572 | static_cast<uint32_t>(data.flags)); |
578 | 573 | written_total += WriteArithmetic<uint32_t>(static_cast<uint32_t>(data.flags)); |
@@ -697,23 +692,6 @@ bool SnapshotData::Check() const { |
697 | 692 | return false; |
698 | 693 | } |
699 | 694 |
|
700 | | - if (metadata.type == SnapshotMetadata::Type::kFullyCustomized && |
701 | | - !WithoutCodeCache(metadata.flags)) { |
702 | | - uint32_t current_cache_version = v8::ScriptCompiler::CachedDataVersionTag(); |
703 | | - if (metadata.v8_cache_version_tag != current_cache_version) { |
704 | | - // For now we only do this check for the customized snapshots - we know |
705 | | - // that the flags we use in the default snapshot are limited and safe |
706 | | - // enough so we can relax the constraints for it. |
707 | | - fprintf(stderr, |
708 | | - "Failed to load the startup snapshot because it was built with " |
709 | | - "a different version of V8 or with different V8 configurations.\n" |
710 | | - "Expected tag %" PRIx32 ", read %" PRIx32 "\n", |
711 | | - current_cache_version, |
712 | | - metadata.v8_cache_version_tag); |
713 | | - return false; |
714 | | - } |
715 | | - } |
716 | | - |
717 | 695 | // TODO(joyeecheung): check incompatible Node.js flags. |
718 | 696 | return true; |
719 | 697 | } |
@@ -1180,7 +1158,6 @@ ExitCode SnapshotBuilder::CreateSnapshot(SnapshotData* out, |
1180 | 1158 | per_process::metadata.versions.node, |
1181 | 1159 | per_process::metadata.arch, |
1182 | 1160 | per_process::metadata.platform, |
1183 | | - v8::ScriptCompiler::CachedDataVersionTag(), |
1184 | 1161 | config->flags}; |
1185 | 1162 |
|
1186 | 1163 | // We cannot resurrect the handles from the snapshot, so make sure that |
|