Fixing calling into code. Interpreter can now be used.

This commit is contained in:
Ben Vanik 2013-05-23 15:44:45 -07:00
parent 9487fa027c
commit f08e80efbc
3 changed files with 4 additions and 3 deletions

View File

@ -55,7 +55,7 @@ LibjitEmitter::LibjitEmitter(xe_memory_ref memory, jit_context_t context) {
// TODO(benvanik): evaluate using jit_abi_fastcall
jit_type_t fn_params[] = {
jit_type_void_ptr,
jit_type_uint
jit_type_nuint,
};
fn_signature_ = jit_type_create_signature(
jit_abi_cdecl,

View File

@ -79,7 +79,8 @@ int LibjitJIT::Execute(xe_ppc_state_t* ppc_state, FunctionSymbol* fn_symbol) {
}
// Call into the function. This will compile it if needed.
intptr_t args[] = {(intptr_t)ppc_state, ppc_state->lr};
jit_nuint lr = ppc_state->lr;
void* args[] = {&ppc_state, &lr};
uint64_t return_value;
int apply_result = jit_function_apply(jit_fn, (void**)&args, &return_value);
if (!apply_result) {

2
third_party/libjit vendored

@ -1 +1 @@
Subproject commit f2628ca8f394d6aa905404b57e78db2cf531e5bc
Subproject commit a43165d21fa428b3184b596cf09a03779223f6ea