From 249415e0143d372032bbbb017e8451c2888c674f Mon Sep 17 00:00:00 2001 From: kettenis Date: Tue, 24 Jan 2017 08:09:05 +0000 Subject: 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@ --- sys/lib/libkern/bzero.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'sys/lib/libkern/bzero.c') diff --git a/sys/lib/libkern/bzero.c b/sys/lib/libkern/bzero.c index d6dac657802..76d37a94ffb 100644 --- a/sys/lib/libkern/bzero.c +++ b/sys/lib/libkern/bzero.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bzero.c,v 1.9 2014/06/10 04:16:57 deraadt Exp $ */ +/* $OpenBSD: bzero.c,v 1.10 2017/01/24 08:09:05 kettenis Exp $ */ /* * Copyright (c) 1987 Regents of the University of California. @@ -31,6 +31,8 @@ #include +#undef bzero + /* * bzero -- vax movc5 instruction */ -- cgit v1.2.3-59-g8ed1b