1 //===-- XCoreTargetObjectFile.h - XCore Object Info -------------*- 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 #ifndef LLVM_LIB_TARGET_XCORE_XCORETARGETOBJECTFILE_H
11 #define LLVM_LIB_TARGET_XCORE_XCORETARGETOBJECTFILE_H
12 
13 #include "llvm/CodeGen/TargetLoweringObjectFileImpl.h"
14 
15 namespace llvm {
16 
17 static const unsigned CodeModelLargeSize = 256;
18 
19   class XCoreTargetObjectFile : public TargetLoweringObjectFileELF {
20     MCSection *BSSSectionLarge;
21     MCSection *DataSectionLarge;
22     MCSection *ReadOnlySectionLarge;
23     MCSection *DataRelROSectionLarge;
24 
25   public:
26     void Initialize(MCContext &Ctx, const TargetMachine &TM) override;
27 
28     MCSection *getExplicitSectionGlobal(const GlobalObject *GO, SectionKind Kind,
29                                         const TargetMachine &TM) const override;
30 
31     MCSection *SelectSectionForGlobal(const GlobalObject *GO, SectionKind Kind,
32                                       const TargetMachine &TM) const override;
33 
34     MCSection *getSectionForConstant(const DataLayout &DL, SectionKind Kind,
35                                      const Constant *C,
36                                      unsigned &Align) const override;
37   };
38 } // end namespace llvm
39 
40 #endif
41