# KernelError: recursion is currently not supported

**URL:** <https://discourse.julialang.org/t/kernelerror-recursion-is-currently-not-supported/33233>\
**Category:** GPU\
**Created:** [January 11, 2020, 7:42am UTC](https://discourse.julialang.org/t/kernelerror-recursion-is-currently-not-supported/33233 "2020-01-11T07:42:31Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![maleadt](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/maleadt/32/10097_2.png) [@maleadt](https://discourse.julialang.org/u/maleadt)\
**Post date:** [January 11, 2020, 4:06pm UTC](https://discourse.julialang.org/t/kernelerror-recursion-is-currently-not-supported/33233/2 "2020-01-11T16:06:48Z")

</div>

You ar calling `det` on the GPU, which in turn calls `mapreduce`. That kind of functionality is not available within a kernel, where you can only do relatively simple computations. The array allocation in `test` is also not possible in a kernel. Just hard-code the expression to calculate the determinant of your 3x3 matrix. Or you could try using StaticArrays, which you can allocate in a kernel (since it’s stack based), and it looks like they provide a `det` method.

---

_[View the full topic](https://discourse.julialang.org/t/kernelerror-recursion-is-currently-not-supported/33233)._
