Coverage Report

Created: 2019-07-24 05:18

/Users/buildslave/jenkins/workspace/clang-stage2-coverage-R/llvm/lib/Target/Lanai/LanaiTargetMachine.h
Line
Count
Source (jump to first uncovered line)
1
//===-- LanaiTargetMachine.h - Define TargetMachine for Lanai --- C++ ---===//
2
//
3
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4
// See https://llvm.org/LICENSE.txt for license information.
5
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6
//
7
//===----------------------------------------------------------------------===//
8
//
9
// This file declares the Lanai specific subclass of TargetMachine.
10
//
11
//===----------------------------------------------------------------------===//
12
13
#ifndef LLVM_LIB_TARGET_LANAI_LANAITARGETMACHINE_H
14
#define LLVM_LIB_TARGET_LANAI_LANAITARGETMACHINE_H
15
16
#include "LanaiFrameLowering.h"
17
#include "LanaiISelLowering.h"
18
#include "LanaiInstrInfo.h"
19
#include "LanaiSelectionDAGInfo.h"
20
#include "LanaiSubtarget.h"
21
#include "llvm/CodeGen/TargetFrameLowering.h"
22
#include "llvm/Target/TargetMachine.h"
23
24
namespace llvm {
25
class formatted_raw_ostream;
26
27
class LanaiTargetMachine : public LLVMTargetMachine {
28
  LanaiSubtarget Subtarget;
29
  std::unique_ptr<TargetLoweringObjectFile> TLOF;
30
31
public:
32
  LanaiTargetMachine(const Target &TheTarget, const Triple &TargetTriple,
33
                     StringRef Cpu, StringRef FeatureString,
34
                     const TargetOptions &Options,
35
                     Optional<Reloc::Model> RelocationModel,
36
                     Optional<CodeModel::Model> CodeModel,
37
                     CodeGenOpt::Level OptLevel, bool JIT);
38
39
  const LanaiSubtarget *
40
1.12k
  getSubtargetImpl(const llvm::Function & /*Fn*/) const override {
41
1.12k
    return &Subtarget;
42
1.12k
  }
43
44
  TargetTransformInfo getTargetTransformInfo(const Function &F) override;
45
46
  // Pass Pipeline Configuration
47
  TargetPassConfig *createPassConfig(PassManagerBase &pass_manager) override;
48
49
504
  TargetLoweringObjectFile *getObjFileLowering() const override {
50
504
    return TLOF.get();
51
504
  }
52
53
0
  bool isMachineVerifierClean() const override {
54
0
    return false;
55
0
  }
56
};
57
} // namespace llvm
58
59
#endif // LLVM_LIB_TARGET_LANAI_LANAITARGETMACHINE_H