@@ -570,12 +570,12 @@ bool OsSyscallExceptionHandler::handle_exception(
570
570
571
571
#if 1
572
572
printf (
573
- " Exception cause %d instruction PC 0x%08lx next PC 0x%08lx jump branch "
574
- " PC 0x%08lx "
575
- " registers PC 0x%08lx mem ref 0x%08lx \n " ,
576
- excause, ( unsigned long ) inst_addr.get_raw (), ( unsigned long ) next_addr.get_raw (),
577
- ( unsigned long ) jump_branch_pc.get_raw (), ( unsigned long ) regs->read_pc ().get_raw (),
578
- ( unsigned long ) mem_ref_addr.get_raw ());
573
+ " Exception cause %d instruction PC 0x%08 " PRIx64 " next PC 0x%08 " PRIx64 " jump branch "
574
+ " PC 0x%08 " PRIx64
575
+ " registers PC 0x%08 " PRIx64 " mem ref 0x%08 " PRIx64 " \n " ,
576
+ excause, inst_addr.get_raw (), next_addr.get_raw (),
577
+ jump_branch_pc.get_raw (), regs->read_pc ().get_raw (),
578
+ mem_ref_addr.get_raw ());
579
579
#else
580
580
(void)excause;
581
581
(void)inst_addr;
@@ -607,7 +607,7 @@ bool OsSyscallExceptionHandler::handle_exception(
607
607
608
608
#if 1
609
609
printf (
610
- " Syscall %s number %ld /0x%lx a1=%" PRIu64 " a2=%" PRIu64 " a3=%" PRIu64 " a4=%" PRIu64 " \n " ,
610
+ " Syscall %s number %" PRId64 " /0x%" PRIx64 " a1=%" PRIu64 " a2=%" PRIu64 " a3=%" PRIu64 " a4=%" PRIu64 " \n " ,
611
611
sdesc->name , syscall_num, syscall_num, a1.as_u64 (), a2.as_u64 (), a3.as_u64 (), a4.as_u64 ());
612
612
613
613
#endif
@@ -787,7 +787,8 @@ int OsSyscallExceptionHandler::syscall_default_handler(
787
787
const rv_syscall_desc_t *sdesc = &rv_syscall_args[syscall_num];
788
788
#if 1
789
789
printf (
790
- " Unimplemented syscall %s number %ld/0x%lx a1 %ld a2 %ld a3 %ld a4 %ld\n " , sdesc->name ,
790
+ " Unimplemented syscall %s number %" PRId64 " /0x%" PRIx64 " a1 %" PRId64
791
+ " a2 %" PRId64 " a3 %" PRId64 " a4 %" PRId64 " \n " , sdesc->name ,
791
792
syscall_num, syscall_num, a1, a2, a3, a4);
792
793
793
794
#endif
@@ -1052,7 +1053,7 @@ int OsSyscallExceptionHandler::do_sys_openat(
1052
1053
1053
1054
result = 0 ;
1054
1055
if (int64_t (a1) != TARGET_AT_FDCWD) {
1055
- printf (" Unimplemented openat argument a1 %ld " , a1);
1056
+ printf (" Unimplemented openat argument a1 %" PRId64 , a1);
1056
1057
if (unknown_syscall_stop) { emit core->stop_on_exception_reached (); }
1057
1058
return TARGET_ENOSYS;
1058
1059
}
0 commit comments