Coverage Report

Created: 2017-04-29 12:21

/Users/buildslave/jenkins/sharedspace/clang-stage2-coverage-R@2/llvm/tools/polly/lib/Analysis/ScopPass.cpp
Line
Count
Source
1
//===- ScopPass.cpp - The base class of Passes that operate on Polly IR ---===//
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
// This file contains the definitions of the ScopPass members.
11
//
12
//===----------------------------------------------------------------------===//
13
14
#include "polly/ScopPass.h"
15
#include "polly/ScopInfo.h"
16
17
using namespace llvm;
18
using namespace polly;
19
20
4.89k
bool ScopPass::runOnRegion(Region *R, RGPassManager &RGM) {
21
4.89k
  S = nullptr;
22
4.89k
23
4.89k
  if ((S = getAnalysis<ScopInfoRegionPass>().getScop()))
24
1.24k
    return runOnScop(*S);
25
4.89k
26
3.64k
  return false;
27
4.89k
}
28
29
1.13k
void ScopPass::print(raw_ostream &OS, const Module *M) const {
30
1.13k
  if (S)
31
293
    printScop(OS, *S);
32
1.13k
}
33
34
518
void ScopPass::getAnalysisUsage(AnalysisUsage &AU) const {
35
518
  AU.addRequired<ScopInfoRegionPass>();
36
518
  AU.setPreservesAll();
37
518
}