Taking a look at what is left in the src tree for compiler optimizer
workarounds it looks like there are some that can most likely be
garbage collected for sparc / alpha and sh now that they have
much newer compilers.

sparc and alpha both having been updated through gcc3 and gcc4
in the timeframe these workarounds have been in the tree and sh
being updated from gcc3 to gcc4.


Index: Makefile
===================================================================
RCS file: /home/cvs/src/sbin/dump/Makefile,v
retrieving revision 1.10
diff -u -p -r1.10 Makefile
--- Makefile    10 Apr 2001 20:52:10 -0000      1.10
+++ Makefile    24 Jul 2012 05:07:43 -0000
@@ -18,8 +18,4 @@ SRCS= itime.c main.c optr.c dumprmt.c ta
 MAN=   dump.8
 MLINKS+=dump.8 rdump.8
 
-.if (${MACHINE_ARCH} == "sparc")
-CFLAGS+= -O0
-.endif
-
 .include <bsd.prog.mk>


Index: Makefile
===================================================================
RCS file: /home/cvs/src/gnu/usr.sbin/mkhybrid/mkhybrid/Makefile,v
retrieving revision 1.5
diff -u -p -r1.5 Makefile
--- Makefile    23 Jun 2011 22:46:12 -0000      1.5
+++ Makefile    24 Jul 2012 05:05:04 -0000
@@ -21,10 +21,6 @@ CFLAGS+=-DSYSTEM_ID_DEFAULT=\"OpenBSD\" 
        -I${.CURDIR}/../src/libhfs_iso \
        -I${.CURDIR}/../src/libfile
 
-# XXX: alpha gcc bug
-write.o: write.c
-       ${CC} ${CFLAGS} -O0 -c ${.CURDIR}/../src/write.c
-
 mkhybrid.8: mkhybrid.8tbl
        cp ${.ALLSRC} ${.TARGET}
 


Index: usr.bin/sort/Makefile
===================================================================
RCS file: /home/cvs/src/usr.bin/sort/Makefile,v
retrieving revision 1.3
diff -u -p -r1.3 Makefile
--- usr.bin/sort/Makefile       13 Mar 2007 17:35:13 -0000      1.3
+++ usr.bin/sort/Makefile       24 Jul 2012 04:55:01 -0000
@@ -3,9 +3,4 @@
 PROG=  sort
 SRCS=  append.c fields.c files.c fsort.c init.c msort.c sort.c tmp.c
 
-# Work around gcc optimization bug on sh
-.if (${MACHINE_ARCH} == sh)
-COPTS+= -O1
-.endif
-
 .include <bsd.prog.mk>
Index: usr.bin/tic/Makefile
===================================================================
RCS file: /home/cvs/src/usr.bin/tic/Makefile,v
retrieving revision 1.5
diff -u -p -r1.5 Makefile
--- usr.bin/tic/Makefile        23 Jun 2011 22:46:12 -0000      1.5
+++ usr.bin/tic/Makefile        24 Jul 2012 04:54:19 -0000
@@ -10,10 +10,6 @@ CURSES=      ${.CURDIR}/../../lib/libcurses
 CFLAGS+= -I${CURSES} -I${.CURDIR} -I.
 CLEANFILES+= termsort.c captoinfo.1
 
-.if (${MACHINE_ARCH} == sh)
-COPTS+=        -O1
-.endif
-
 beforedepend: termsort.c
 
 termsort.c: MKtermsort.sh

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

Reply via email to