summaryrefslogtreecommitdiff
path: root/ir_cudarose.hh
diff options
context:
space:
mode:
authordhuth <derickhuth@gmail.com>2014-08-27 09:52:06 -0600
committerdhuth <derickhuth@gmail.com>2014-08-27 09:52:06 -0600
commitbff810cc371a38f493d688c54f71013f5a7d53bf (patch)
treefbe86954bb3c01deb21da9e41ebff5baa2889a45 /ir_cudarose.hh
downloadchill-bff810cc371a38f493d688c54f71013f5a7d53bf.tar.gz
chill-bff810cc371a38f493d688c54f71013f5a7d53bf.tar.bz2
chill-bff810cc371a38f493d688c54f71013f5a7d53bf.zip
Initial commit
Diffstat (limited to 'ir_cudarose.hh')
-rw-r--r--ir_cudarose.hh46
1 files changed, 46 insertions, 0 deletions
diff --git a/ir_cudarose.hh b/ir_cudarose.hh
new file mode 100644
index 0000000..34e0404
--- /dev/null
+++ b/ir_cudarose.hh
@@ -0,0 +1,46 @@
+#ifndef IR_CUDA_ROSE
+#define IR_CUDA_ROSE
+
+#include <code_gen/CG_roseRepr.h>
+#include <code_gen/CG_roseBuilder.h>
+#include "ir_rose.hh"
+#include "loop.hh"
+#include "loop_cuda_rose.hh"
+#include "ir_rose_utils.hh"
+
+
+
+class IR_cudaroseCode : public IR_roseCode{
+
+public:
+
+
+ IR_cudaroseCode(const char *filename, const char* proc_name);
+
+
+
+ SgGlobal *gsym_;
+ SgScopeStatement* defn;
+ SgGlobal* first_scope;
+ SgSymbolTable* parameter;
+ SgSymbolTable* body;
+ SgFunctionDefinition* func_defn;
+ std::vector<SgSymbolTable*> write_procs;//procs to write
+
+
+ IR_ArraySymbol *CreateArraySymbol(const IR_Symbol *sym, std::vector<omega::CG_outputRepr *> &size,int sharedAnnotation = 1);
+ omega::CG_outputRepr* init_code(){ return init_code_; }
+ bool commit_loop(Loop *loop, int loop_num);
+ std::vector<SgForStatement *> get_loops()
+ {
+ std::vector<SgForStatement *> loops = find_loops(func->get_definition()->get_body());
+ return loops;
+ }
+
+ ~IR_cudaroseCode();
+
+};
+
+
+#endif
+