diff options
author | Thomas Lively <7121787+tlively@users.noreply.github.com> | 2019-04-15 15:57:36 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-15 15:57:36 -0700 |
commit | cb2d63586c08a3dd194d2b733ceb3f5051c081f8 (patch) | |
tree | bea80c167f03c920224fbd47fd6422ac5624372c /src | |
parent | 1e91e1b666cc76874732d27843d0048c15b6152b (diff) | |
download | binaryen-cb2d63586c08a3dd194d2b733ceb3f5051c081f8.tar.gz binaryen-cb2d63586c08a3dd194d2b733ceb3f5051c081f8.tar.bz2 binaryen-cb2d63586c08a3dd194d2b733ceb3f5051c081f8.zip |
Do not emit the DataCount section (#2010)
Its presence was causing validation errors in the Emscripten test
suite. This should be reverted once the default feature set is no
longer All.
Diffstat (limited to 'src')
-rw-r--r-- | src/wasm/wasm-binary.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/wasm/wasm-binary.cpp b/src/wasm/wasm-binary.cpp index f3642203d..d6091e93c 100644 --- a/src/wasm/wasm-binary.cpp +++ b/src/wasm/wasm-binary.cpp @@ -317,9 +317,14 @@ void WasmBinaryWriter::writeDataCount() { if (!wasm->features.hasBulkMemory() || !wasm->memory.segments.size()) { return; } - auto start = startSection(BinaryConsts::Section::DataCount); - o << U32LEB(wasm->memory.segments.size()); - finishSection(start); + + // TODO(tlively): re-enable writing the data count once the default feature + // set is no longer All, which causes validation errors in Emscripten due to + // the presence of an unrecognized section. + + // auto start = startSection(BinaryConsts::Section::DataCount); + // o << U32LEB(wasm->memory.segments.size()); + // finishSection(start); } void WasmBinaryWriter::writeDataSegments() { |