aboutsummaryrefslogtreecommitdiff
path: root/lib/Transforms/IPO/Cilkifier.h
blob: be79ab6b22249b124e44c7cd9439394e2bd0b0ea (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
//===- Cilkifier.h - Support routines for Cilk code generation --*- C++ -*-===//
//
// This is located here so that the code generator (dis) does not have to
// include and link with the libtipo.a archive containing class Cilkifier
// and the rest of the automatic parallelization code.
//===----------------------------------------------------------------------===//

#ifndef LLVM_SUPPORT_CILKIFIER_H
#define LLVM_SUPPORT_CILKIFIER_H

#include <string>
class Function;
class CallInst;


//---------------------------------------------------------------------------- 
// Global constants used in marking Cilk functions and function calls.
// These should be used only by the auto-parallelization pass.
//---------------------------------------------------------------------------- 

extern const std::string  CilkSuffix;
extern const std::string  DummySyncFuncName;

//---------------------------------------------------------------------------- 
// Routines to identify Cilk functions, calls to Cilk functions, and syncs.
//---------------------------------------------------------------------------- 

extern bool  isCilk     (const Function& F);
extern bool  isCilkMain (const Function& F);
extern bool  isCilk     (const CallInst& CI);
extern bool  isSync     (const CallInst& CI);

//===----------------------------------------------------------------------===//

#endif