Calling to/from native works!
This commit is contained in:
parent
0c127828af
commit
37f93d2974
|
@ -186,6 +186,7 @@ int LibjitEmitter::MakeFunction(FunctionSymbol* symbol, jit_function_t gen_fn) {
|
|||
}
|
||||
|
||||
if (!result_code) {
|
||||
// TODO(benvanik): flag
|
||||
// pre
|
||||
jit_dump_function(stdout, gen_fn_, symbol->name());
|
||||
jit_function_compile(gen_fn_);
|
||||
|
|
|
@ -100,10 +100,10 @@ int LibjitJIT::Execute(xe_ppc_state_t* ppc_state, FunctionSymbol* fn_symbol) {
|
|||
}
|
||||
|
||||
// TODO(benvanik): replace generic apply with special trampoline.
|
||||
void* args[] = {&ppc_state, &ppc_state->lr};
|
||||
intptr_t args[] = {(intptr_t)ppc_state, ppc_state->lr};
|
||||
uint64_t return_value;
|
||||
int apply_result = jit_function_apply(jit_fn, (void**)&args, &return_value);
|
||||
if (apply_result) {
|
||||
if (!apply_result) {
|
||||
XELOGCPU("Execute(%.8X): apply failed with %d",
|
||||
fn_symbol->start_address, apply_result);
|
||||
return 1;
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit bd2b2e2bf04ca423e23b67eaff92fc623f687e92
|
||||
Subproject commit 61b04ce23f04165c6d3041927a4bc62b53e8b032
|
Loading…
Reference in New Issue