diff options
author | Dan Gohman <dan433584@gmail.com> | 2015-11-11 01:33:02 +0000 |
---|---|---|
committer | Dan Gohman <dan433584@gmail.com> | 2015-11-11 01:33:02 +0000 |
commit | 754cd11d9019e62a4c6a0aee62159e707f6f51d9 (patch) | |
tree | 8431ec606891d373ee34cba87fcb5fdc4a1b6e70 /llvm/lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.h | |
parent | dc9c5df5cdf4af06179f77a4b451369fcc82aef8 (diff) | |
download | bcm5719-llvm-754cd11d9019e62a4c6a0aee62159e707f6f51d9.tar.gz bcm5719-llvm-754cd11d9019e62a4c6a0aee62159e707f6f51d9.zip |
[WebAssembly] Support non-legal argument and return types.
llvm-svn: 252687
Diffstat (limited to 'llvm/lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.h')
-rw-r--r-- | llvm/lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.h b/llvm/lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.h index a571e63d7f6..bac0dfafcf3 100644 --- a/llvm/lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.h +++ b/llvm/lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.h @@ -27,15 +27,19 @@ namespace llvm { class WebAssemblyFunctionInfo final : public MachineFunctionInfo { MachineFunction &MF; - unsigned NumArguments; + std::vector<MVT> Params; + std::vector<MVT> Results; public: explicit WebAssemblyFunctionInfo(MachineFunction &MF) - : MF(MF), NumArguments(0) {} + : MF(MF) {} ~WebAssemblyFunctionInfo() override; - void setNumArguments(unsigned N) { NumArguments = N; } - unsigned getNumArguments() const { return NumArguments; } + void addParam(MVT VT) { Params.push_back(VT); } + const std::vector<MVT> &getParams() const { return Params; } + + void addResult(MVT VT) { Results.push_back(VT); } + const std::vector<MVT> &getResults() const { return Results; } }; } // end namespace llvm |