search for: c_thunk

Displaying 4 results from an estimated 4 matches for "c_thunk".

2012 Mar 22
0
[LLVMdev] Catching C++ exceptions, cleaning up, rethrowing
...think this has anything to do with LLVM's IR-level exception system. It sounds to me like you just need a way to handle C++ exceptions inside of the C++ code and then rethrow so that the JIT's caller can do its thing. (Right?) Right. The call sequence is: my_lib(1) -> JIT_code -> C_thunk -> my_lib(2) The JIT code creates Functions that create C++ objects on their stacks (by using alloca instructions then calling a C thunk that calls the C++ object's constructor via placement new). If an exception is thrown in my_lib(2), then somewhere between there and when the stack unwin...
2012 Mar 21
1
[LLVMdev] Catching C++ exceptions, cleaning up, rethrowing
To recap, on Mar 14, 2012, I wrote: > My project has a C++ library that I want to allow the user to use via some programming language to be JIT'd to call functions in said library. For the sake of simplicity, assume the library has classes like: > > class item_iterator { > public: > virtual ~item_iterator(); > virtual bool next( item *result ) = 0; > }; >
2012 Mar 22
1
[LLVMdev] Catching C++ exceptions, cleaning up, rethrowing
On Mar 20, 2012, at 7:38 PM, Paul J. Lucas wrote: > To recap, on Mar 14, 2012, I wrote: > >> My project has a C++ library that I want to allow the user to use via some programming language to be JIT'd to call functions in said library. For the sake of simplicity, assume the library has classes like: >> >> class item_iterator { >> public: >> virtual
2012 Mar 23
2
[LLVMdev] Catching C++ exceptions, cleaning up, rethrowing
...hing to do with LLVM's IR-level exception system. It sounds to me like you just need a way to handle C++ exceptions inside of the C++ code and then rethrow so that the JIT's caller can do its thing. (Right?) > > Right. The call sequence is: > > my_lib(1) -> JIT_code -> C_thunk -> my_lib(2) > > The JIT code creates Functions that create C++ objects on their stacks (by using alloca instructions then calling a C thunk that calls the C++ object's constructor via placement new). If an exception is thrown in my_lib(2), then somewhere between there and when the s...