This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] C undefined behavior fix
- From: "Joseph S. Myers" <jsm28 at cam dot ac dot uk>
- To: Tom Rini <trini at kernel dot crashing dot org>
- Cc: Momchil Velikov <velco at fadata dot bg>, <linux-kernel at vger dot kernel dot org>, <gcc at gcc dot gnu dot org>, <linuxppc-dev at lists dot linuxppc dot org>
- Date: Wed, 2 Jan 2002 14:56:03 +0000 (GMT)
- Subject: Re: [PATCH] C undefined behavior fix
On Tue, 1 Jan 2002, Tom Rini wrote:
> 3) We could also try turning off this particular optimization
> (-fno-builtin perhaps) on this file, and not worry about it.
In particular, it would probably make sense for the kernel to use
-ffreestanding (which implies -fno-builtin) throughout then selectively
enable the built-in functions that are wanted with macros such as
#define strcpy(d, s) __builtin_strcpy((d), (s))
in an appropriate header, then #undef these macros in the files that
shouldn't use the built-in functions.
--
Joseph S. Myers
jsm28@cam.ac.uk