Re: CVS commit: src/sys/arch/macppc/stand/bootxx

2018-03-02 Thread Sevan Janiyan


On 03/03/18 02:06, matthew green wrote:
> you didn't grep enough :-)  eg:
> 
> dist/gcc/config/rs6000/rs6000.c:prefix = (sel & SAVRES_SAVE) ? 
> "_savegpr_" : "_restgpr_";
> 
> is the part that matters.

Just so I understand, where does this come into play from the bootxx
side, reason I ask is there is no noise in the build output. bootxx
compiles without warnings or complaint (I haven't touched the verbosity
settings). Would problems with this binary be expected on execution &
not during build?

> i don't know you can easily test it.  i would recommend
> putting the old code back for ${HAVE_GCC:U0} > 0 builds.

Like so?


Index: sys/arch/macppc/stand/bootxx/Makefile
===
RCS file: /cvsroot/src/sys/arch/macppc/stand/bootxx/Makefile,v
retrieving revision 1.18
diff -u -p -r1.18 Makefile
--- sys/arch/macppc/stand/bootxx/Makefile   2 Mar 2018 23:15:25
-   1.18
+++ sys/arch/macppc/stand/bootxx/Makefile   3 Mar 2018 03:22:09 -
@@ -23,6 +23,11 @@ CLEANFILES+= ${PROG}.sym

 ${PROG}: ${OBJS}
${_MKTARGET_LINK}
+.if ${HAVE_GCC:U0} > 0
+   ${LD} -o ${.TARGET}.sym ${LINKFLAGS} ${OBJS}
${DESTDIR}/usr/lib/libgcc.a
+.else
+   ${LD} -o ${.TARGET}.sym ${LINKFLAGS} ${OBJS}
+.endif
${LD} -o ${.TARGET}.sym ${LINKFLAGS} ${OBJS}
${OBJCOPY} -O binary ${.TARGET}.sym ${.TARGET}



Re: CVS commit: src/sys/arch/macppc/stand/bootxx

2018-03-02 Thread Sevan Janiyan


On 03/03/18 02:06, matthew green wrote:
> you didn't grep enough :-)  eg:

Bah! :)

> dist/gcc/config/rs6000/rs6000.c:prefix = (sel & SAVRES_SAVE) ? 
> "_savegpr_" : "_restgpr_";
> 
> is the part that matters.
> 
> i don't know you can easily test it.  i would recommend
> putting the old code back for ${HAVE_GCC:U0} > 0 builds.

Ok

Sevan


re: CVS commit: src/sys/arch/macppc/stand/bootxx

2018-03-02 Thread matthew green
> I did see that but thought that we'd had a toolchain update since then.
> grepping the source, the only place I see a reference to it is in
> external/gpl3/gcc/dist/libgcc/config/rs6000/crtresxgpr.S:HIDDEN_FUNC(_restgpr_30_x)
> lwz 30,-8(11)
> external/gpl3/gcc/dist/libgcc/config/rs6000/crtresxgpr.S:FUNC_END(_restgpr_30_x)
> external/gpl3/gcc.old/dist/libgcc/config/rs6000/crtresxgpr.S:HIDDEN_FUNC(_restgpr_30_x)
> lwz 30,-8(11)
> external/gpl3/gcc.old/dist/libgcc/config/rs6000/crtresxgpr.S:FUNC_END(_restgpr_30_x)

you didn't grep enough :-)  eg:

dist/gcc/config/rs6000/rs6000.c:prefix = (sel & SAVRES_SAVE) ? 
"_savegpr_" : "_restgpr_";

is the part that matters.

i don't know you can easily test it.  i would recommend
putting the old code back for ${HAVE_GCC:U0} > 0 builds.


.mrg.


Re: CVS commit: src/sys/arch/macppc/conf

2018-03-02 Thread Michael
Hello,

On Sat, 3 Mar 2018 00:27:51 +
"Sevan Janiyan"  wrote:

> Module Name:  src
> Committed By: sevan
> Date: Sat Mar  3 00:27:51 UTC 2018
> 
> Modified Files:
>   src/sys/arch/macppc/conf: POWERMAC_G5
> 
> Log Message:
> Return recent changes to configuration file.
> Remove legacy options previously removed e.g MACHO & softdep support
> Remove bogus numbers
> Add or update descriptions
> Keep items removed in previous commit commented out

Thanks!

have fun
Michael


Re: CVS commit: src/sys/arch/macppc/stand/bootxx

2018-03-02 Thread Valery Ushakov
On Sat, Mar 03, 2018 at 00:39:30 +, Sevan Janiyan wrote:

> On 03/02/18 23:22, Valery Ushakov wrote:
> > I wonder if this might be dependendent on compiler options &c (e.g. on
> > sh4 gcc will emit calls to some libgcc functions only for some
> > optimization settings).
> 
> hmm, do you have some optimisation settings in mind that I should test??

I'm not familiar with gcc ppc internals.

-uwe


Re: CVS commit: src/sys/arch/macppc/stand/bootxx

2018-03-02 Thread Sevan Janiyan


On 03/02/18 23:22, Valery Ushakov wrote:
> I wonder if this might be dependendent on compiler options &c (e.g. on
> sh4 gcc will emit calls to some libgcc functions only for some
> optimization settings).

hmm, do you have some optimisation settings in mind that I should test??


Sevan


Re: CVS commit: src/sys/arch/macppc/stand/bootxx

2018-03-02 Thread Sevan Janiyan


On 03/02/18 23:22, Valery Ushakov wrote:
> That was introduced rather recently:
> 
>   revision 1.17
>   date: 2017-07-16 02:26:46 +0300;  author: christos;
>   branches:  1.17.2;
>   Avoid missing _restgpr_30_x

I did see that but thought that we'd had a toolchain update since then.
grepping the source, the only place I see a reference to it is in
external/gpl3/gcc/dist/libgcc/config/rs6000/crtresxgpr.S:HIDDEN_FUNC(_restgpr_30_x)
lwz 30,-8(11)
external/gpl3/gcc/dist/libgcc/config/rs6000/crtresxgpr.S:FUNC_END(_restgpr_30_x)
external/gpl3/gcc.old/dist/libgcc/config/rs6000/crtresxgpr.S:HIDDEN_FUNC(_restgpr_30_x)
lwz 30,-8(11)
external/gpl3/gcc.old/dist/libgcc/config/rs6000/crtresxgpr.S:FUNC_END(_restgpr_30_x)

> I wonder if this might be dependendent on compiler options &c (e.g. on
> sh4 gcc will emit calls to some libgcc functions only for some
> optimization settings).

for my release build with GCC, I just did ./build.sh -m macppc release
for the LLVM build I did
./build.sh -V MKLLVM=yes -V HAVE_LLVM=yes -V MKGCC=no -m macppc release

I'd actually built the LLVM release using the following patch but opted
to remove the reference to libgcc.a when the default build passed on the
basis that I'd wait for the daily releng builds to see.

Index: sys/arch/macppc/stand/bootxx/Makefile
===
RCS file: /cvsroot/src/sys/arch/macppc/stand/bootxx/Makefile,v
retrieving revision 1.17
diff -u -p -r1.17 Makefile
--- sys/arch/macppc/stand/bootxx/Makefile   15 Jul 2017 23:26:46
-  1.17
+++ sys/arch/macppc/stand/bootxx/Makefile   2 Mar 2018 20:13:38 -
@@ -23,7 +23,7 @@ CLEANFILES+=  ${PROG}.sym

 ${PROG}: ${OBJS}
${_MKTARGET_LINK}
-   ${LD} -o ${.TARGET}.sym ${LINKFLAGS} ${OBJS}
${DESTDIR}/usr/lib/libgcc.a
+   ${LD} -o ${.TARGET}.sym ${LINKFLAGS} ${OBJS} ${${ACTIVE_CC} ==
"gcc":? ${DESTDIR}/usr/lib/libgcc.a :}
${OBJCOPY} -O binary ${.TARGET}.sym ${.TARGET}

 .include 



Re: CVS commit: src/sys/arch/macppc/stand/bootxx

2018-03-02 Thread Valery Ushakov
On Fri, Mar 02, 2018 at 23:15:25 +, Sevan Janiyan wrote:

> Module Name:  src
> Committed By: sevan
> Date: Fri Mar  2 23:15:25 UTC 2018
> 
> Modified Files:
>   src/sys/arch/macppc/stand/bootxx: Makefile
> 
> Log Message:
> Do not pass libgcc.a to linker as it breaks build with MKGCC=no e.g
> HEAD-LLVM.  It doesn't appear to be required for the stock GCC build
> either, having been able to build a release without it.

That was introduced rather recently:

  revision 1.17
  date: 2017-07-16 02:26:46 +0300;  author: christos;
  branches:  1.17.2;
  Avoid missing _restgpr_30_x

I wonder if this might be dependendent on compiler options &c (e.g. on
sh4 gcc will emit calls to some libgcc functions only for some
optimization settings).

-uwe