summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkettenis <kettenis@openbsd.org>2016-09-06 18:33:35 +0000
committerkettenis <kettenis@openbsd.org>2016-09-06 18:33:35 +0000
commitc9c2859665c8c0ee56e6a9243efd7faf9b4d81d1 (patch)
treeb4d7279d267cde812209b7b6aee05c2447ff6c51
parentuse closefrom() before reexec to make sure the new process only gets (diff)
downloadwireguard-openbsd-c9c2859665c8c0ee56e6a9243efd7faf9b4d81d1.tar.xz
wireguard-openbsd-c9c2859665c8c0ee56e6a9243efd7faf9b4d81d1.zip
Remove branch prediction hints from conditional branch instructions. These
hints are not recognized by clang's builtin assembler and the opcode prefixes they generate have been no-ops for all CPUs after the Pentium 4. ok guenther@
-rw-r--r--lib/libc/arch/amd64/SYS.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/arch/amd64/SYS.h b/lib/libc/arch/amd64/SYS.h
index 3479377f801..e20e50c7875 100644
--- a/lib/libc/arch/amd64/SYS.h
+++ b/lib/libc/arch/amd64/SYS.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: SYS.h,v 1.19 2016/05/07 19:05:21 guenther Exp $ */
+/* $OpenBSD: SYS.h,v 1.20 2016/09/06 18:33:35 kettenis Exp $ */
/*-
* Copyright (c) 1990 The Regents of the University of California.
@@ -60,7 +60,7 @@
movl %eax,%fs:(TCB_OFFSET_ERRNO); \
movq $-1, %rax
#define HANDLE_ERRNO \
- jnc,pt 99f; \
+ jnc 99f; \
SET_ERRNO; \
99:
@@ -84,7 +84,7 @@
/* return, handling errno for failed calls */
#define _RSYSCALL_RET \
- jc,pn 99f; \
+ jc 99f; \
ret; \
99: SET_ERRNO; \
ret