1 // WebAssemblyDebugValueManager.h - WebAssembly DebugValue Manager -*- C++ -*-// 2 // 3 // The LLVM Compiler Infrastructure 4 // 5 // This file is distributed under the University of Illinois Open Source 6 // License. See LICENSE.TXT for details. 7 // 8 //===----------------------------------------------------------------------===// 9 /// 10 /// \file 11 /// This file contains the declaration of the WebAssembly-specific 12 /// manager for DebugValues associated with the specific MachineInstr. 13 /// 14 //===----------------------------------------------------------------------===// 15 16 #ifndef LLVM_LIB_TARGET_WEBASSEMBLY_WEBASSEMBLYDEBUGVALUEMANAGER_H 17 #define LLVM_LIB_TARGET_WEBASSEMBLY_WEBASSEMBLYDEBUGVALUEMANAGER_H 18 19 #include "llvm/ADT/SmallVector.h" 20 21 namespace llvm { 22 23 class MachineInstr; 24 25 class WebAssemblyDebugValueManager { 26 SmallVector<MachineInstr *, 2> DbgValues; 27 28 public: 29 WebAssemblyDebugValueManager(MachineInstr *Instr); 30 31 void move(MachineInstr *Insert); 32 void updateReg(unsigned Reg); 33 void clone(MachineInstr *Insert, unsigned NewReg); 34 }; 35 36 } // end namespace llvm 37 38 #endif 39