Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restrict work group size for elementwise kernel #26

Closed
johanneskoester opened this issue Jan 20, 2014 · 2 comments
Closed

Restrict work group size for elementwise kernel #26

johanneskoester opened this issue Jan 20, 2014 · 2 comments

Comments

@johanneskoester
Copy link

For the ElementwiseKernel, there is no mechanism to determine the work group size before invocation. Sometimes, this is a problem, e.g. if you want to allocate local memory proportional to the expected work group size.

What is the best pattern to overcome this limitation? Would it be a good idea to incorporate a mechanism for controlling the work group size before invocation into ElementwiseKernel?

Thanks in advance,
Johannes

@inducer
Copy link
Owner

inducer commented Jan 20, 2014

I'm sort of against that. ElementwiseKernel is intended for simple things. As soon as you allocate local memory, what you're doing is no longer simple, to my mind. Specifically, workgroups are an unexposed implementation detail of ElementwiseKernel. As soon as you want the level of control you describe, I feel like you should graduate to just a plain old kernel invocation.

Sorry,
Andreas

@inducer inducer closed this as completed Jan 20, 2014
@johanneskoester
Copy link
Author

I see. Ok, I'm fine with that. Thanks for the advice, Andreas!

2014/1/20 Andreas Klöckner notifications@github.com

I'm sort of against that. ElementwiseKernel is intended for simple
things. As soon as you allocate local memory, what you're doing is no
longer simple, to my mind. Specifically, workgroups are an unexposed
implementation detail of ElementwiseKernel. As soon as you want the level
of control you describe, I feel like you should graduate to just a plain
old kernel invocation.

Sorry,
Andreas


Reply to this email directly or view it on GitHubhttps://github.com//issues/26#issuecomment-32796813
.

Dipl.-Inf. Johannes Köster
http://johanneskoester.bitbucket.org

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

No branches or pull requests

2 participants