On Tue, Apr 21, 2015 at 12:35 PM, Joel (Xi Zhou) Zhou
<joel.z...@broadcom.com> wrote:
> The u-boot built with gcc-linaro-arm-none-eabi-4.9-2014.09_linux can boot on
> the development board. This toolchain was pre-built toolchain from Linaro,
> built with crosstool-NG. The version is gcc version 4.9.2 20140904
> (prerelease) (crosstool-NG linaro-1.13.1-4.9-2014.09 - Linaro GCC
> 4.9-2014.09)
>
> With the same u-boot source, the binary built with the Linaro gcc 4.9
> 2015.04 hang on the same board. The 2nd toolchain was compiled locally on
> RHEL6, built with ABE tool. We build it locally to avoid “GLIBC_2.14 not
> found” issue on the pre-built toolchain. The version is gcc version 4.9.3
> 20150413 (prerelease) (Linaro GCC 2015.04)

The older toolchain is built with crosstool-NG.  The newer one is
built with ABE.  There are likely some subtle differences in behaviour
between them, and this might be causing the problem.  This would not
be a problem normally, but low level code like bootloaders are more
sensitive to these kinds of things.  Or it could be a latent bug in
the new release.

Since you have one compiler that works and one that doesn't, I would
suggest that you try mixing them to isolate the problem.  Compile
uboot with the old release and link with the new release to see if
that works.  Compile uboot with the new release and link with the old
release to see if that works.  That should isolate the problem to
either gcc or binutils.  If it is the new gcc that is broken, then try
reducing compiler optimization levels to see if that helps.  If it
does help, then you can do bisection across the source tree to try to
find one file that causes a failure at high optimization levels but
works at low optimization levels.  You can then debug from there.  If
it is the new binutils that is the problem, then you can try using
objdump and/or readelf to look for subtle differences in the output
that might be causing problems.

Jim
_______________________________________________
linaro-toolchain mailing list
linaro-toolchain@lists.linaro.org
https://lists.linaro.org/mailman/listinfo/linaro-toolchain

Reply via email to