summaryrefslogtreecommitdiffstats
path: root/lld/wasm/MarkLive.cpp
diff options
context:
space:
mode:
authorHeejin Ahn <aheejin@gmail.com>2018-12-08 06:17:43 +0000
committerHeejin Ahn <aheejin@gmail.com>2018-12-08 06:17:43 +0000
commite915a71f183a0d921f67dc1a95238885bcafeec8 (patch)
tree5fe7f26b14d29e41c8a9a9efd38aaebade20ce22 /lld/wasm/MarkLive.cpp
parenta2125b8d9953e3720e9a9ec621ccbfd5f2cd78f0 (diff)
downloadbcm5719-llvm-e915a71f183a0d921f67dc1a95238885bcafeec8.tar.gz
bcm5719-llvm-e915a71f183a0d921f67dc1a95238885bcafeec8.zip
[WebAssembly] Add support for the event section
Summary: This adds support for the 'event section' specified in the exception handling proposal. Wasm exception handling binary model spec: https://github.com/WebAssembly/exception-handling/blob/master/proposals/Exceptions.md#changes-to-the-binary-model Reviewers: sbc100, ruiu Subscribers: dschuff, jgravelle-google, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D54875 llvm-svn: 348703
Diffstat (limited to 'lld/wasm/MarkLive.cpp')
-rw-r--r--lld/wasm/MarkLive.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lld/wasm/MarkLive.cpp b/lld/wasm/MarkLive.cpp
index 7f4696bced9..3bbd1148f6a 100644
--- a/lld/wasm/MarkLive.cpp
+++ b/lld/wasm/MarkLive.cpp
@@ -22,6 +22,7 @@
#include "MarkLive.h"
#include "Config.h"
#include "InputChunks.h"
+#include "InputEvent.h"
#include "InputGlobal.h"
#include "SymbolTable.h"
#include "Symbols.h"
@@ -105,6 +106,9 @@ void lld::wasm::markLive() {
for (InputGlobal *G : Obj->Globals)
if (!G->Live)
message("removing unused section " + toString(G));
+ for (InputEvent *E : Obj->Events)
+ if (!E->Live)
+ message("removing unused section " + toString(E));
}
for (InputChunk *C : Symtab->SyntheticFunctions)
if (!C->Live)
OpenPOWER on IntegriCloud