diff options
author | 2017-01-24 08:09:05 +0000 | |
---|---|---|
committer | 2017-01-24 08:09:05 +0000 | |
commit | 249415e0143d372032bbbb017e8451c2888c674f (patch) | |
tree | 3c5623aa41410b8a985bc7929b7b111ca2493d47 /sys/lib/libkern/bcmp.c | |
parent | pfind(9) has been renamed to tfind(9); (diff) | |
download | wireguard-openbsd-249415e0143d372032bbbb017e8451c2888c674f.tar.xz wireguard-openbsd-249415e0143d372032bbbb017e8451c2888c674f.zip |
In preparation of compiling our kernels with -ffreestanding, explicitly map
a few performance-critical functions to compiler builtins. Since the
builtins supported by gcc3, gcc4 and clang are not the same, there are
(unfortunately) some compiler checks to make sure we only do the mapping
for builtins that are actually supported by the compiler.
ok jca@, tom@, guenther@
Diffstat (limited to 'sys/lib/libkern/bcmp.c')
-rw-r--r-- | sys/lib/libkern/bcmp.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/lib/libkern/bcmp.c b/sys/lib/libkern/bcmp.c index e9e1aba7f44..821339b5ab9 100644 --- a/sys/lib/libkern/bcmp.c +++ b/sys/lib/libkern/bcmp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bcmp.c,v 1.10 2014/06/10 04:16:57 deraadt Exp $ */ +/* $OpenBSD: bcmp.c,v 1.11 2017/01/24 08:09:05 kettenis Exp $ */ /* * Copyright (c) 1987 Regents of the University of California. @@ -31,6 +31,8 @@ #include <lib/libkern/libkern.h> +#undef bcmp + /* * bcmp -- vax cmpc3 instruction */ |