[saga-rg] Task model...

Hartmut Kaiser hkaiser at cct.lsu.edu
Thu Nov 3 19:04:33 CST 2005


John Shalf wrote:

> > It's not a matter of simplifying the implementation, it's a
> matter of
> > simplifying the exposed interface. I even would go for a
> more complex
> > implementation if the interface gets simpler. And from my
> experience
> > the templated syntax isn't counterintuitive if you're used to
> > programming in
> > C++.
>
> Its not clear to me that C++ requires use of templates to be
> C++- like.

It was not my intent to say that. What I was trying to say was that if
you're going to use C++ then templates will be a powerful and versatile
tool.

> I typically think of using templates where the
> algorithm is the same but the types that have to be passed
> through the algorithm may differ in different
> implementations. I'm still having a difficult time wrapping
> my mind around the concept of using templates where the
> underlying algorithm will be very different.

That's the initial use case which lead to the addition of templates to the
language. As I said, templates are turing complete and thus usable (and
used!) for generic metaprogramming - a powerful tool for letting the
compiler generate optimal code.

Regards Hartmut







More information about the saga-rg mailing list