Skip to content
This repository has been archived by the owner on Jan 26, 2024. It is now read-only.

Make examples self-contained without using the C++ Dispatcher #16

Open
almson opened this issue Aug 25, 2016 · 0 comments
Open

Make examples self-contained without using the C++ Dispatcher #16

almson opened this issue Aug 25, 2016 · 0 comments

Comments

@almson
Copy link

almson commented Aug 25, 2016

The over-engineered Dispatcher class makes it more difficult to understand how to launch kernels. I suggest each asm example to have two host source files. One which uses C HSA code and another which uses C++ HCC code. If any common functionality should be factored out into a common file, then that functionality should take the form of simple non-OOP utility functions. Samples should be as simple as possible and easy to build on top of and incorporate into other code.

The choice to use C++ to call HSA is especially odd. We have HCC for that. The HSA examples should use pure C and not attempt to create yet another layer of abstraction.

Thankfully, there is currently /opt/rocm/hsa/sample/vector_copy.c, although it doesn't load HSACO files.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant