summaryrefslogtreecommitdiff
path: root/src/wasm.h
diff options
context:
space:
mode:
authorAlon Zakai <azakai@google.com>2020-03-30 11:14:29 -0700
committerGitHub <noreply@github.com>2020-03-30 11:14:29 -0700
commitd8179402b3bb991f336b19bcca8ccbc60c842166 (patch)
treec70757545451aaebc75d74bede99fe5c1576d90b /src/wasm.h
parent2b758fbdc46fc8fe5241bcf1ba5bbd81e6d556ed (diff)
downloadbinaryen-d8179402b3bb991f336b19bcca8ccbc60c842166.tar.gz
binaryen-d8179402b3bb991f336b19bcca8ccbc60c842166.tar.bz2
binaryen-d8179402b3bb991f336b19bcca8ccbc60c842166.zip
Represent dylink section in IR, so we can update it. (#2715)
Update it from wasm-emscripten-finalize when we append to the table.
Diffstat (limited to 'src/wasm.h')
-rw-r--r--src/wasm.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/wasm.h b/src/wasm.h
index 21fef1049..73f22e7d7 100644
--- a/src/wasm.h
+++ b/src/wasm.h
@@ -1460,6 +1460,13 @@ public:
std::vector<char> data;
};
+// The optional "dylink" section is used in dynamic linking.
+class DylinkSection {
+public:
+ Index memorySize, memoryAlignment, tableSize, tableAlignment;
+ std::vector<Name> neededDynlibs;
+};
+
class Module {
public:
// wasm contents (generally you shouldn't access these from outside, except
@@ -1475,6 +1482,9 @@ public:
std::vector<UserSection> userSections;
+ // Optional user section IR representation.
+ std::unique_ptr<DylinkSection> dylinkSection;
+
// Source maps debug info.
std::vector<std::string> debugInfoFileNames;