From ff2b60bbcb28701c86b200b0c03439a2e6ef6b44 Mon Sep 17 00:00:00 2001 From: Matt Arsenault Date: Wed, 2 Nov 2022 14:46:00 -0700 Subject: WebAssembly: Remove MachineFunction reference from MFI The MachineFunctionInfo here is a bit awkward because WasmEHInfo is in the MachineFunction but handled from the target code. Either everything should move into WebAssembly or into the MachineFunction for MIR serialization. --- llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp') diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp b/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp index 76f036358ae8..9e4a30323b99 100644 --- a/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp +++ b/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp @@ -585,7 +585,7 @@ WebAssemblyTargetMachine::createDefaultFuncInfoYAML() const { yaml::MachineFunctionInfo *WebAssemblyTargetMachine::convertFuncInfoToYAML( const MachineFunction &MF) const { const auto *MFI = MF.getInfo(); - return new yaml::WebAssemblyFunctionInfo(*MFI); + return new yaml::WebAssemblyFunctionInfo(MF, *MFI); } bool WebAssemblyTargetMachine::parseMachineFunctionInfo( @@ -593,6 +593,6 @@ bool WebAssemblyTargetMachine::parseMachineFunctionInfo( SMDiagnostic &Error, SMRange &SourceRange) const { const auto &YamlMFI = static_cast(MFI); MachineFunction &MF = PFS.MF; - MF.getInfo()->initializeBaseYamlFields(YamlMFI); + MF.getInfo()->initializeBaseYamlFields(MF, YamlMFI); return false; } -- cgit v1.2.3