[WebAssembly] Add except_ref as a first-class type
authorHeejin Ahn <aheejin@gmail.com>
Thu, 8 Mar 2018 04:06:57 +0000 (04:06 +0000)
committerHeejin Ahn <aheejin@gmail.com>
Thu, 8 Mar 2018 04:06:57 +0000 (04:06 +0000)
Summary:
Add except_ref as a first-class type, according to the [[https://github.com/WebAssembly/exception-handling/blob/master/proposals/Level-1.md | Level 1 exception handling proposal ]].
Companion to D43706.

Reviewers: sbc100

Subscribers: jfb, dschuff, jgravelle-google, sunfish, llvm-commits

Differential Revision: https://reviews.llvm.org/D43707

llvm-svn: 326986

lld/wasm/WriterUtils.cpp

index 5f7b4a2..ac3a19f 100644 (file)
@@ -174,6 +174,8 @@ std::string lld::toString(ValType Type) {
     return "F32";
   case ValType::F64:
     return "F64";
+  case ValType::EXCEPT_REF:
+    return "except_ref";
   }
   llvm_unreachable("Invalid wasm::ValType");
 }