Date: Fri, 21 Jan 2011 17:15:11 +1100 (EST) From: Bruce Evans <brde@optusnet.com.au> To: Matthew Jacob <mj@feral.com> Cc: freebsd-arch@freebsd.org Subject: Re: removing -frename-registers from sys/conf.mk Message-ID: <20110121162202.S2816@besplex.bde.org> In-Reply-To: <4D38D49A.2010909@feral.com> References: <4D38CAEE.2060705@feral.com> <4D38D49A.2010909@feral.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 20 Jan 2011, Matthew Jacob wrote: > Never mind this ill thought out request. > > On 1/20/2011 3:53 PM, Matthew Jacob wrote: >> It helps substantially in trying to debug amd64 kernels to remove this >> flag. >> >> Has anyone heard of a good reason we need to keep this? Whom else should I >> ask? What's ill-thought out about it? It may be bad for debugging, but can hardly be as bad as -O2 and a couple other optimizations now under -O, at least with ddb. gdb with full debugging info can sometimes follow when the code was reordered, but it has to show all the reordering when stepping. I didn't know about -frename-registers and just tried it on libm. It gives only pessimizations of up to 60% on (uncommitted) log functions in the float precision case. This turned out to be just a pessimization that I've seen before and had worked around, but the workaround stopped working with -frename-registers. gcc and clang in FreeBSD don't really understand SSE, so they like to try to generate partial register stalls, which cost 20-30 cycles on at least AthlonXP, Athlon64 and core2. Fortunately, the stall doesn't occur in most cases where it might happen. Bruce
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110121162202.S2816>