blob: 8d74c5ccb7675a7567bb0bf57aae8aca7c58be14 [file] [log] [blame]
Scott Michel266bc8f2007-12-04 22:23:35 +00001//===-- SPUHazardRecognizers.h - Cell SPU Hazard Recognizer -----*- C++ -*-===//
2//
3// The LLVM Compiler Infrastructure
4//
Chris Lattner4ee451d2007-12-29 20:36:04 +00005// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
Scott Michel266bc8f2007-12-04 22:23:35 +00007//
8//===----------------------------------------------------------------------===//
9//
10// This file defines hazard recognizers for scheduling on the Cell SPU
11// processor.
12//
13//===----------------------------------------------------------------------===//
14
15#ifndef SPUHAZRECS_H
16#define SPUHAZRECS_H
17
18#include "llvm/CodeGen/ScheduleDAG.h"
19#include "SPUInstrInfo.h"
20
21namespace llvm {
22
23/// SPUHazardRecognizer
24class SPUHazardRecognizer : public HazardRecognizer
25{
26private:
27 const TargetInstrInfo &TII;
28 int EvenOdd;
29
30public:
31 SPUHazardRecognizer(const TargetInstrInfo &TII);
32 virtual HazardType getHazardType(SDNode *Node);
33 virtual void EmitInstruction(SDNode *Node);
34 virtual void AdvanceCycle();
35 virtual void EmitNoop();
36};
37
38} // end namespace llvm
39
40#endif
41