blob: 813ceba063bdf5af321c41f49530bae3c799aa4b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
//===-- PIC16FrameOverlay.h - Interface for PIC16 Frame Overlay -*- C++ -*-===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
//
// This file contains the PIC16 Frame Overlay infrastructure.
//
//===----------------------------------------------------------------------===//
#ifndef PIC16FRAMEOVERLAY_H
#define PIC16FRAMEOVERLAY_H
#include "llvm/Analysis/CallGraph.h"
#include "llvm/Pass.h"
#include "llvm/Module.h"
#include "llvm/Support/raw_ostream.h"
#include <vector>
#include <iostream>
using std::vector;
using std::string;
using namespace llvm;
namespace {
class PIC16FrameOverlay : public ModulePass {
public:
static char ID; // Class identification
PIC16FrameOverlay() : ModulePass(&ID) {}
virtual void getAnalysisUsage(AnalysisUsage &AU) const;
virtual bool runOnModule(Module &M);
private:
void ColorFunction(CallGraphNode *CGN, unsigned Color);
};
char PIC16FrameOverlay::ID = 0;
static RegisterPass<PIC16FrameOverlay>
Y("pic16overlay", "PIC16 Frame Overlay Analysis");
} // End of namespace
#endif
|