18#define GET_REGINFO_ENUM
19#include "WebAssemblyGenRegisterInfo.inc"
25 .
Case(
"i32", MVT::i32)
26 .
Case(
"i64", MVT::i64)
27 .
Case(
"f32", MVT::f32)
28 .
Case(
"f64", MVT::f64)
29 .
Case(
"i64", MVT::i64)
30 .
Case(
"v16i8", MVT::v16i8)
31 .
Case(
"v8i16", MVT::v8i16)
32 .
Case(
"v4i32", MVT::v4i32)
33 .
Case(
"v2i64", MVT::v2i64)
34 .
Case(
"funcref", MVT::funcref)
35 .
Case(
"externref", MVT::externref)
36 .
Case(
"exnref", MVT::exnref)
41 switch (
Type.SimpleTy) {
43 return wasm::ValType::I32;
45 return wasm::ValType::I64;
47 return wasm::ValType::F32;
49 return wasm::ValType::F64;
57 return wasm::ValType::V128;
59 return wasm::ValType::FUNCREF;
61 return wasm::ValType::EXTERNREF;
63 return wasm::ValType::EXNREF;
82 ValTy = wasm::ValType::EXTERNREF;
84 ValTy = wasm::ValType::FUNCREF;
87 }
else if (VTs.
size() == 1) {
94 Sym->setTableType(ValTy);
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
This file implements the StringSwitch template, which mimics a switch() statement whose cases are str...
This file contains the declaration of the WebAssembly-specific type parsing utility functions.
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
size_t size() const
size - Get the array size.
@ INVALID_SIMPLE_VALUE_TYPE
StringRef - Represent a constant reference to a string, i.e.
A switch()-like statement whose cases are string literals.
StringSwitch & Case(StringLiteral S, T Value)
The instances of the Type class are immutable: once they are created, they are never changed.
Type * getArrayElementType() const
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
bool isWebAssemblyExternrefType(const Type *Ty)
Return true if this is a WebAssembly Externref Type.
bool isWebAssemblyFuncrefType(const Type *Ty)
Return true if this is a WebAssembly Funcref Type.
wasm::ValType toValType(MVT Type)
bool isWebAssemblyTableType(const Type *Ty)
Return true if the table represents a WebAssembly table type.
void wasmSymbolSetType(MCSymbolWasm *Sym, const Type *GlobalVT, ArrayRef< MVT > VTs)
Sets a Wasm Symbol Type.
MVT parseMVT(StringRef Type)
@ WASM_SYMBOL_TYPE_GLOBAL
This is an optimization pass for GlobalISel generic memory operations.
void report_fatal_error(Error Err, bool gen_crash_diag=true)
Report a serious error, calling any installed error handler.