Fix timer_semantics tests

Summary: The default opt-level was recently lowered from 1 to 0. `syscalls::syscall!(...)` has one branch to check the error code while `syscalls::raw_syscall!()` does not. Presumably, this branch was getting optimized out when opt-level=1, but not when opt-level=0 and thus started causing the highly-sensitive timer tests to start failing.

Reviewed By: VladimirMakaev

Differential Revision: D47892355

fbshipit-source-id: 9d19d4a1a1e0521650ffcb46a93f4a61a07bcae1
This commit is contained in:
Jason White 2023-07-29 03:49:57 -07:00 committed by Facebook GitHub Bot
parent 22fa391dda
commit 7d704c86c6

View file

@ -289,7 +289,7 @@ mod tests {
#[inline(always)]
unsafe fn syscall_no_branches(no: Sysno, arg1: libc::c_long) {
syscalls::syscall!(no, arg1, 0, 0, 0, 0, 0);
syscalls::raw_syscall!(no, arg1, 0, 0, 0, 0, 0);
}
fn sched_precise() {