Commit 6098ddea authored by Dan Elphick's avatar Dan Elphick Committed by Commit Bot

[snapshot] Ensure padding is always cleared in tests

Re-enables and fixes msan test failures due to string padding being
cleared only selectively in tests. This change instead makes sure it
always happens in TestIsolate.

Bug: v8:7746
Change-Id: I259b43ad25cb7af18bf16d29effb15772c981a67
Reviewed-on: https://chromium-review.googlesource.com/1051647Reviewed-by: 's avatarPeter Marshall <petermarshall@chromium.org>
Reviewed-by: 's avatarJakob Gruber <jgruber@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53095}
parent d096508f
......@@ -198,11 +198,6 @@
['msan == True', {
# ICU upstream issues.
'test-strings/CountBreakIterator': [SKIP],
# https://crbug.com/v8/7746
# MSan issues after landing https://crrev.com/c/1046657
'test-serialize/StartupSerializerOnce': [SKIP],
'test-serialize/StartupSerializerTwice': [SKIP],
}], # 'msan == True'
##############################################################################
......
......@@ -81,6 +81,7 @@ class TestIsolate : public Isolate {
v8::Isolate* v8_isolate = reinterpret_cast<v8::Isolate*>(isolate);
v8::Isolate::Scope isolate_scope(v8_isolate);
isolate->Init(nullptr);
isolate->heap()->read_only_space()->ClearStringPaddingIfNeeded();
return v8_isolate;
}
// Wraps v8::Isolate::New, but with a TestIsolate under the hood.
......@@ -458,7 +459,6 @@ static void PartiallySerializeContext(Vector<const byte>* startup_blob_out,
env.Reset();
isolate->heap()->read_only_space()->ClearStringPaddingIfNeeded();
SnapshotByteSink startup_sink;
StartupSerializer startup_serializer(isolate);
startup_serializer.SerializeStrongReferences();
......@@ -583,7 +583,6 @@ static void PartiallySerializeCustomContext(
env.Reset();
isolate->heap()->read_only_space()->ClearStringPaddingIfNeeded();
SnapshotByteSink startup_sink;
StartupSerializer startup_serializer(isolate);
startup_serializer.SerializeStrongReferences();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment