directives in delite!

10 views
Skip to first unread message

Mohamad Rezaei

unread,
May 21, 2014, 12:35:56 PM5/21/14
to opt...@googlegroups.com
Hi,

I am not sure if I am asking this right or not, but I wanted to somehow implement declaratives in the dsl (like openmp). I am not sure if this is the right way or not but I wanted some how after AST stage to tell which library should be chosen. At start I want to just use my dsl as shell for executing libraries underneath.

Thanks.

Arvind Sujeeth

unread,
May 22, 2014, 1:37:31 PM5/22/14
to opt...@googlegroups.com
You could define stage-time config flags (just ordinary Scala values), that you set statically, read from Java properties, or read from a configuration file. Then during staging you can override the IR node construction methods to check the flag and construct the corresponding node.

Alternatively, to give finer-grained control to the user, you could have the DSL methods themselves accept a (non-Rep) parameter specifying which which library to use, and use that parameter to construct the appropriate IR node.

Arvind
--
You received this message because you are subscribed to the Google Groups "OptiML" group.
To unsubscribe from this group and stop receiving emails from it, send an email to optiml+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages