On 03/16/2011 11:41 PM, Daniel Schwierzeck wrote:
> Is my approach with -march acceptable? This is more important to me
> for supporting new SoCs with 24k and 34k CPU cores. I think its a
> clean approach to use a default Mips32 architecture optimization plus
> a per CPU optimization configured in the SoC directories.

IIUC this is a binutils related issue.

> @@ -20,20 +20,13 @@
>  # Foundation, Inc., 59 Temple Place, Suite 330, Boston,
>  # MA 02111-1307 USA
>  #
> -v=$(shell $(AS) --version | grep 'GNU assembler' | egrep -o '2\.[0-9\.]+' | 
> cut -d. -f2)
> -MIPSFLAGS:=$(shell \
> -if [ "$v" -lt "14" ]; then \
> -     echo "-mcpu=4kc"; \
> -else \
> -     echo "-march=4kc -mtune=4kc"; \
> -fi)
> 
> [...]
> +# Optimization flags for all Mips32 CPUs
> +MIPSFLAGS = $(call cc-option,-march=mips32r2,-mips32r2 -Wa,-mips32r2)

According to GNU gas NEWS, mips32r2 support was introduced in 2.14:

http://sourceware.org/cgi-bin/cvsweb.cgi/~checkout~/src/gas/NEWS?rev=1.117&content-type=text/plain&cvsroot=src&only_with_tag=binutils-binutils-2_21

On the other hand, we have a number of the ELDK releases so far, and
their binutils versions vary from 2.11 (ELDK2.1.0) to 2.16.1 (ELDK4.1).

2.1.0: 
http://mirror.switch.ch/ftp/mirror/eldk/2.1.0/eldk-mips-linux-x86/README.html
3.0:   (N/A for MIPS?)
3.1:   
http://mirror.switch.ch/ftp/mirror/eldk/3.1/mips-linux-x86/distribution/README.html
3.1.1: 
http://mirror.switch.ch/ftp/mirror/eldk/3.1.1/mips-linux-x86/distribution/README.html
4.0:   
http://mirror.switch.ch/ftp/mirror/eldk/4.0/mips-linux-x86/distribution/README.html
       http://www.denx.de/en/News/PressReleaseELDK40
4.1:   
http://mirror.switch.ch/ftp/mirror/eldk/4.1/mips-linux-x86/distribution/README.html
       http://www.denx.de/en/News/PressReleaseELDK41
4.2:   (N/A for MIPS?)

Does above change break any builds with older binutils?  Personally, I'm
ok with dropping older toolchains to some extent.  However, if it breaks
builds with older toolchains, strictly speaking older versions of the
ELDK releases, the decision is up to Wolfgang.

Along with the code, it'd be nice to provide a note in the git commit
log about which ELDK version(s) will be affected by this change.  I'm
not sure that anyone still uses the ELSK2.1.0 in the wild, nor current
U-Boot/MIPS can be built with it, though.
_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to