build: fix travis MPI/SMP build
[charm.git] / src / xlat-i / xi-Construct.h
blob80e0df3b848c9638339f9585baa124efb3d7a427
1 #ifndef _CONSTRUCT_H
2 #define _CONSTRUCT_H
4 #include "xi-AstNode.h"
6 namespace xi {
8 class Module;
10 class Construct : public virtual AstNode {
11 protected:
12 int external;
14 public:
15 // FIXME?: isn't this circular since Module < Construct?
16 Module* containerModule;
17 explicit Construct();
18 void setExtern(int& e);
19 void setModule(Module* m);
20 virtual bool isTramTarget() { return false; }
23 // FIXME?: shouldn't the "public virtual" be here instead of in the Construct baseclass?
24 class ConstructList : public AstChildren<Construct>, public Construct {
25 public:
26 ConstructList(int l, Construct* c, ConstructList* n = 0);
27 using AstChildren<Construct>::isTramTarget;
30 /******************** AccelBlock : Block of code for accelerator **********************/
31 class AccelBlock : public Construct {
32 protected:
33 XStr* code;
35 private:
36 void outputCode(XStr& str);
38 public:
39 /// Constructor(s)/Destructor ///
40 AccelBlock(int l, XStr* c);
41 ~AccelBlock();
43 /// Printable Methods ///
44 void print(XStr& str);
46 /// Construct Methods ///
47 void genDefs(XStr& str);
49 /// Construct Accel Support Methods ///
50 int genAccels_spe_c_funcBodies(XStr& str);
53 } // namespace xi
55 #endif // ifndef _CONSTRUCT_H