gpu_neon: fix some missing ebuf updates
[pcsx_rearmed.git] / deps / libretro-common / libco / genode.cpp
1 /*
2   libco.genode_secondary_stack (2018-09-15)
3   author: Emery Hemingway
4   license: public domain
5 */
6
7 /* Genode include */
8 #include <base/thread.h>
9
10 /* Libco include */
11 #include <libco.h>
12
13 extern "C"
14 void *genode_alloc_secondary_stack(unsigned long stack_size)
15 {
16         try
17    {
18                 return Genode::Thread::myself()->alloc_secondary_stack("libco", stack_size);
19    }
20         catch (...)
21    {
22                 Genode::error("libco: failed to allocate ", stack_size, " byte secondary stack");
23                 return nullptr;
24         }
25 }
26
27 extern "C"
28 void genode_free_secondary_stack(void *stack)
29 {
30         Genode::Thread::myself()->free_secondary_stack(stack);
31 }