LCOV - code coverage report
Current view: top level - build-llvm/lib/Target/XCore - XCoreGenSubtargetInfo.inc (source / functions) Hit Total Coverage
Test: llvm-toolchain.info Lines: 5 9 55.6 %
Date: 2017-09-14 15:23:50 Functions: 2 6 33.3 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /*===- TableGen'erated file -------------------------------------*- C++ -*-===*\
       2             : |*                                                                            *|
       3             : |* Subtarget Enumeration Source Fragment                                      *|
       4             : |*                                                                            *|
       5             : |* Automatically generated file, do not edit!                                 *|
       6             : |*                                                                            *|
       7             : \*===----------------------------------------------------------------------===*/
       8             : 
       9             : 
      10             : #ifdef GET_SUBTARGETINFO_ENUM
      11             : #undef GET_SUBTARGETINFO_ENUM
      12             : 
      13             : namespace llvm {
      14             : } // end namespace llvm
      15             : 
      16             : #endif // GET_SUBTARGETINFO_ENUM
      17             : 
      18             : 
      19             : #ifdef GET_SUBTARGETINFO_MC_DESC
      20             : #undef GET_SUBTARGETINFO_MC_DESC
      21             : 
      22             : namespace llvm {
      23             : 
      24             : // Sorted (by key) array of values for CPU subtype.
      25             : extern const llvm::SubtargetFeatureKV XCoreSubTypeKV[] = {
      26             :   { "generic", "Select the generic processor", { }, { } },
      27             :   { "xs1b-generic", "Select the xs1b-generic processor", { }, { } }
      28             : };
      29             : 
      30             : #ifdef DBGFIELD
      31             : #error "<target>GenSubtargetInfo.inc requires a DBGFIELD macro"
      32             : #endif
      33             : #ifndef NDEBUG
      34             : #define DBGFIELD(x) x,
      35             : #else
      36             : #define DBGFIELD(x)
      37             : #endif
      38             : 
      39             : // ===============================================================
      40             : // Data tables for the new per-operand machine model.
      41             : 
      42             : // {ProcResourceIdx, Cycles}
      43             : extern const llvm::MCWriteProcResEntry XCoreWriteProcResTable[] = {
      44             :   { 0,  0}, // Invalid
      45             : }; // XCoreWriteProcResTable
      46             : 
      47             : // {Cycles, WriteResourceID}
      48             : extern const llvm::MCWriteLatencyEntry XCoreWriteLatencyTable[] = {
      49             :   { 0,  0}, // Invalid
      50             : }; // XCoreWriteLatencyTable
      51             : 
      52             : // {UseIdx, WriteResourceID, Cycles}
      53             : extern const llvm::MCReadAdvanceEntry XCoreReadAdvanceTable[] = {
      54             :   {0,  0,  0}, // Invalid
      55             : }; // XCoreReadAdvanceTable
      56             : 
      57             : static const llvm::MCSchedModel NoSchedModel = {
      58             :   MCSchedModel::DefaultIssueWidth,
      59             :   MCSchedModel::DefaultMicroOpBufferSize,
      60             :   MCSchedModel::DefaultLoopMicroOpBufferSize,
      61             :   MCSchedModel::DefaultLoadLatency,
      62             :   MCSchedModel::DefaultHighLatency,
      63             :   MCSchedModel::DefaultMispredictPenalty,
      64             :   false, // PostRAScheduler
      65             :   false, // CompleteModel
      66             :   0, // Processor ID
      67             :   nullptr, nullptr, 0, 0, // No instruction-level machine model.
      68             :   nullptr}; // No Itinerary
      69             : 
      70             : // Sorted (by key) array of itineraries for CPU subtype.
      71             : extern const llvm::SubtargetInfoKV XCoreProcSchedKV[] = {
      72             :   { "generic", (const void *)&NoSchedModel },
      73             :   { "xs1b-generic", (const void *)&NoSchedModel }
      74             : };
      75             : #undef DBGFIELD
      76          81 : static inline MCSubtargetInfo *createXCoreMCSubtargetInfoImpl(const Triple &TT, StringRef CPU, StringRef FS) {
      77             :   return new MCSubtargetInfo(TT, CPU, FS, None, XCoreSubTypeKV, 
      78             :                       XCoreProcSchedKV, XCoreWriteProcResTable, XCoreWriteLatencyTable, XCoreReadAdvanceTable, 
      79         243 :                       nullptr, nullptr, nullptr);
      80             : }
      81             : 
      82             : } // end namespace llvm
      83             : 
      84             : #endif // GET_SUBTARGETINFO_MC_DESC
      85             : 
      86             : 
      87             : #ifdef GET_SUBTARGETINFO_TARGET_DESC
      88             : #undef GET_SUBTARGETINFO_TARGET_DESC
      89             : 
      90             : #include "llvm/Support/Debug.h"
      91             : #include "llvm/Support/raw_ostream.h"
      92             : 
      93             : // ParseSubtargetFeatures - Parses features string setting specified
      94             : // subtarget options.
      95           0 : void llvm::XCoreSubtarget::ParseSubtargetFeatures(StringRef CPU, StringRef FS) {
      96             :   DEBUG(dbgs() << "\nFeatures:" << FS);
      97             :   DEBUG(dbgs() << "\nCPU:" << CPU << "\n\n");
      98           0 : }
      99             : #endif // GET_SUBTARGETINFO_TARGET_DESC
     100             : 
     101             : 
     102             : #ifdef GET_SUBTARGETINFO_HEADER
     103             : #undef GET_SUBTARGETINFO_HEADER
     104             : 
     105             : namespace llvm {
     106             : class DFAPacketizer;
     107          78 : struct XCoreGenSubtargetInfo : public TargetSubtargetInfo {
     108             :   explicit XCoreGenSubtargetInfo(const Triple &TT, StringRef CPU, StringRef FS);
     109             : public:
     110             :   unsigned resolveSchedClass(unsigned SchedClass,  const MachineInstr *DefMI, const TargetSchedModel *SchedModel) const override;
     111             :   DFAPacketizer *createDFAPacketizer(const InstrItineraryData *IID) const;
     112             : };
     113             : } // end namespace llvm
     114             : 
     115             : #endif // GET_SUBTARGETINFO_HEADER
     116             : 
     117             : 
     118             : #ifdef GET_SUBTARGETINFO_CTOR
     119             : #undef GET_SUBTARGETINFO_CTOR
     120             : 
     121             : #include "llvm/CodeGen/TargetSchedule.h"
     122             : 
     123             : namespace llvm {
     124             : extern const llvm::SubtargetFeatureKV XCoreFeatureKV[];
     125             : extern const llvm::SubtargetFeatureKV XCoreSubTypeKV[];
     126             : extern const llvm::SubtargetInfoKV XCoreProcSchedKV[];
     127             : extern const llvm::MCWriteProcResEntry XCoreWriteProcResTable[];
     128             : extern const llvm::MCWriteLatencyEntry XCoreWriteLatencyTable[];
     129             : extern const llvm::MCReadAdvanceEntry XCoreReadAdvanceTable[];
     130          80 : XCoreGenSubtargetInfo::XCoreGenSubtargetInfo(const Triple &TT, StringRef CPU, StringRef FS)
     131             :   : TargetSubtargetInfo(TT, CPU, FS, None, makeArrayRef(XCoreSubTypeKV, 2), 
     132             :                         XCoreProcSchedKV, XCoreWriteProcResTable, XCoreWriteLatencyTable, XCoreReadAdvanceTable, 
     133         240 :                         nullptr, nullptr, nullptr) {}
     134             : 
     135           0 : unsigned XCoreGenSubtargetInfo
     136             : ::resolveSchedClass(unsigned SchedClass, const MachineInstr *MI, const TargetSchedModel *SchedModel) const {
     137           0 :   report_fatal_error("Expected a variant SchedClass");
     138             : } // XCoreGenSubtargetInfo::resolveSchedClass
     139             : } // end namespace llvm
     140             : 
     141             : #endif // GET_SUBTARGETINFO_CTOR
     142             : 

Generated by: LCOV version 1.13