Skip to content
Snippets Groups Projects
Commit c7582f44 authored by rtoy's avatar rtoy
Browse files

Move the rules for e_rem_pio2.c and k_rem_pio2.c from GNUmakefile to

Config.linux_gencgc.

This only appears to be an issue on Linux.  FreeBSD and Darwin are
ok.  And it depends on the compiler. gcc 4.2.1 produces bad results,
but gcc 3.4.6 is ok.  Could be an aliasing issue.  So use -O1
everywhere.  -ffloat-store doesn't appear to matter so remove that
too.
parent 1880c4a3
No related branches found
No related tags found
No related merge requests found
......@@ -31,3 +31,17 @@ OS_SRC = Linux-os.c os-common.c elf.c e_rem_pio2.c k_rem_pio2.c
OS_LINK_FLAGS = -rdynamic -Xlinker --export-dynamic -Xlinker -Map -Xlinker foo
OS_LIBS = -ldl
#GC_SRC = gencgc.c
# gcc 4.2.1 on Suse 10.3 appears to mis-compile these files with -O2.
# Hence, compile these with -O1, which appears to work. (Perhaps this
# is an aliasing issue?) To see this failure, try computing (cos
# (expt 2d0 120)). This should be near -0.92587902285....
#
# This appears to be ok with gcc 3.4.6, but we force -O1 everywhere
# since we can't tell what compiler version we're using.
e_rem_pio2.o : e_rem_pio2.c
$(CC) -c $(CFLAGS) -O1 $<
k_rem_pio2.o : k_rem_pio2.c
$(CC) -c $(CFLAGS) -O1 $<
# $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/GNUmakefile,v 1.27 2008/01/18 01:44:18 rtoy Exp $
# $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/GNUmakefile,v 1.28 2008/01/18 14:31:50 rtoy Exp $
all: lisp.nm
......@@ -64,19 +64,4 @@ Depends: ${SRCS}
$(DEPEND) ${DEPEND_FLAGS} ${CFLAGS} ${CPPFLAGS} $^ > ,depends
mv ,depends Depends
# For x86 architectures, these files need to be compiled with
# -ffloat-store to make sure that we get double-float precision
# instead of the default x86 80-bit extended precision.
# gcc 4.2.1 on Suse 10.3 appears to mis-compile these files with -O2.
# Hence, compile these with -O1, which appears to work. To see this
# failure, try computing (cos (expt 2d0 120)). This should be near
# -0.92587902285....
e_rem_pio2.o : e_rem_pio2.c
$(CC) -c $(CFLAGS) -O1 -ffloat-store $(PATH1)/e_rem_pio2.c
k_rem_pio2.o : k_rem_pio2.c
$(CC) -c $(CFLAGS) -O1 -ffloat-store $(PATH1)/k_rem_pio2.c
-include Depends
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment