WARNING! Access to this system is limited to authorised users only.
Unauthorised users may be subject to prosecution.
Unauthorised access to this system is a criminal offence under Australian law (Federal Crimes Act 1914 Part VIA)
It is a criminal offence to:
(1) Obtain access to data without authority. -Penalty 2 years imprisonment.
(2) Damage, delete, alter or insert data without authority. -Penalty 10 years imprisonment.
User activity is monitored and recorded. Anyone using this system expressly consents to such monitoring and recording.

Commit 924e2b3e authored by qinsoon's avatar qinsoon
Browse files

runs on aarch64

parent 30226d91
......@@ -33,7 +33,6 @@ use runtime::entrypoints::RuntimeEntrypoint;
use compiler::CompilerPass;
use compiler::PROLOGUE_BLOCK_NAME;
use compiler::EPILOGUE_BLOCK_NAME;
use compiler::backend::aarch64::*;
use compiler::backend::make_block_name;
......@@ -142,7 +141,7 @@ impl <'a> InstructionSelection {
if use_cbnz { Some(Box::new(tmp_cond.as_ref().unwrap().clone())) }
else { None };
let mut cmpop = self.emit_cmp_res(cond, cond_box, f_content, f_context, vm);
let cmpop = self.emit_cmp_res(cond, cond_box, f_content, f_context, vm);
if use_cbnz {
self.backend.emit_cbnz(tmp_cond.as_ref().unwrap(), branch_target);
......@@ -434,7 +433,8 @@ impl <'a> InstructionSelection {
}
}
self.emit_common_epilogue(f_context, vm);
self.emit_epilogue(f_context, vm);
self.backend.emit_ret(&LR);
},
Instruction_::BinOp(op, op1, op2) => {
......@@ -4538,13 +4538,6 @@ impl CompilerPass for InstructionSelection {
}
fn finish_function(&mut self, vm: &VM, func: &mut MuFunctionVersion) {
// Todo: Don't emit this if the function never returns
let epilogue_block = format!("{}:{}", self.current_fv_name, EPILOGUE_BLOCK_NAME);
self.start_block(epilogue_block);
self.emit_epilogue(&mut func.context, vm);
self.backend.emit_ret(&LR); // return to the Link Register
self.finish_block();
self.backend.print_cur_code();
let func_name = {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment