cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

marxin
Journeyman III

HSA: Kaveri machine does not support recursion functions

Hello.

Recursion calls are explicitly mentioned in the Programmer's reference manual to be supported. However, even quite simple

test, as Fibonacci numbers, does not work.

Is it known issues for the Kaveri machine? If you are interested, I can attach HSAIL code snippet.

Thanks,

Martin

0 Likes
1 Solution
jedwards
Staff

This is not only a limitation on Kaveri, but on any HSA platform using the HSA runtime. Currently the kernel compiler doesn't support the alloca instruction, and without the ability to allocate stack variables on the fly, kernels cannot be recursive. The lack of alloca support is clearly documented in the HSA-Runtime-AMD wiki's section on unimplemented functionality (even if recursion isn't).

The alloca instruction will be supported in an upcoming release (possibly September of 2015). Recursion should be supported at that time.

View solution in original post

0 Likes
2 Replies
jtrudeau
Staff

Welcome marxin​. You are white listed, I'm moving this into the HSA forum.

0 Likes
jedwards
Staff

This is not only a limitation on Kaveri, but on any HSA platform using the HSA runtime. Currently the kernel compiler doesn't support the alloca instruction, and without the ability to allocate stack variables on the fly, kernels cannot be recursive. The lack of alloca support is clearly documented in the HSA-Runtime-AMD wiki's section on unimplemented functionality (even if recursion isn't).

The alloca instruction will be supported in an upcoming release (possibly September of 2015). Recursion should be supported at that time.

0 Likes