X86COFFMachineModuleInfo.h (202878) | X86COFFMachineModuleInfo.h (203954) |
---|---|
1//===-- llvm/CodeGen/X86COFFMachineModuleInfo.h -----------------*- 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//===----------------------------------------------------------------------===// --- 7 unchanged lines hidden (view full) --- 16 17#include "llvm/CodeGen/MachineModuleInfo.h" 18#include "llvm/ADT/StringSet.h" 19#include "X86MachineFunctionInfo.h" 20 21namespace llvm { 22 class X86MachineFunctionInfo; 23 class TargetData; | 1//===-- llvm/CodeGen/X86COFFMachineModuleInfo.h -----------------*- 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//===----------------------------------------------------------------------===// --- 7 unchanged lines hidden (view full) --- 16 17#include "llvm/CodeGen/MachineModuleInfo.h" 18#include "llvm/ADT/StringSet.h" 19#include "X86MachineFunctionInfo.h" 20 21namespace llvm { 22 class X86MachineFunctionInfo; 23 class TargetData; |
24 | 24 |
25/// X86COFFMachineModuleInfo - This is a MachineModuleInfoImpl implementation 26/// for X86 COFF targets. 27class X86COFFMachineModuleInfo : public MachineModuleInfoImpl { 28 StringSet<> CygMingStubs; | 25/// X86COFFMachineModuleInfo - This is a MachineModuleInfoImpl implementation 26/// for X86 COFF targets. 27class X86COFFMachineModuleInfo : public MachineModuleInfoImpl { 28 StringSet<> CygMingStubs; |
29 30 // We have to propagate some information about MachineFunction to 31 // AsmPrinter. It's ok, when we're printing the function, since we have 32 // access to MachineFunction and can get the appropriate MachineFunctionInfo. 33 // Unfortunately, this is not possible when we're printing reference to 34 // Function (e.g. calling it and so on). Even more, there is no way to get the 35 // corresponding MachineFunctions: it can even be not created at all. That's 36 // why we should use additional structure, when we're collecting all necessary 37 // information. 38 // 39 // This structure is using e.g. for name decoration for stdcall & fastcall'ed 40 // function, since we have to use arguments' size for decoration. 41 typedef std::map<const Function*, X86MachineFunctionInfo> FMFInfoMap; 42 FMFInfoMap FunctionInfoMap; 43 | 29 DenseMap<const Function*, unsigned> FnArgWords; |
44public: 45 X86COFFMachineModuleInfo(const MachineModuleInfo &); 46 ~X86COFFMachineModuleInfo(); | 30public: 31 X86COFFMachineModuleInfo(const MachineModuleInfo &); 32 ~X86COFFMachineModuleInfo(); |
47 48 | 33 |
49 void DecorateCygMingName(MCSymbol* &Name, MCContext &Ctx, 50 const GlobalValue *GV, const TargetData &TD); 51 void DecorateCygMingName(SmallVectorImpl<char> &Name, const GlobalValue *GV, 52 const TargetData &TD); | 34 void DecorateCygMingName(MCSymbol* &Name, MCContext &Ctx, 35 const GlobalValue *GV, const TargetData &TD); 36 void DecorateCygMingName(SmallVectorImpl<char> &Name, const GlobalValue *GV, 37 const TargetData &TD); |
53 54 void AddFunctionInfo(const Function *F, const X86MachineFunctionInfo &Val); 55 | |
56 | 38 |
39 void addExternalFunction(const StringRef& Name); |
|
57 typedef StringSet<>::const_iterator stub_iterator; 58 stub_iterator stub_begin() const { return CygMingStubs.begin(); } 59 stub_iterator stub_end() const { return CygMingStubs.end(); } | 40 typedef StringSet<>::const_iterator stub_iterator; 41 stub_iterator stub_begin() const { return CygMingStubs.begin(); } 42 stub_iterator stub_end() const { return CygMingStubs.end(); } |
60 61 | |
62}; 63 64 65 66} // end namespace llvm 67 68#endif | 43}; 44 45 46 47} // end namespace llvm 48 49#endif |