]> git.karo-electronics.de Git - karo-tx-uboot.git/commit
arc: build libgcc in U-Boot
authorAlexey Brodkin <abrodkin@synopsys.com>
Tue, 3 Feb 2015 10:58:20 +0000 (13:58 +0300)
committerLothar Waßmann <LW@KARO-electronics.de>
Tue, 1 Sep 2015 10:59:15 +0000 (12:59 +0200)
commit7f5d06a301ab962aacdfb634c2418cb5823f5f45
tree90a5f95fcb652c3727fe5ab09f285f1607d5aa17
parent94ce155dc56058455971e88b8e859939e922604b
arc: build libgcc in U-Boot

This way we may have very limited set of functions implemented so we
save some space.

Also it allows us to build U-Boot for any ARC core with the same one
toolchain because we don't rely on pre-built libgcc.

For example:
 * we may use little-endian toolchain but build U-Boot for ether
endianess
 * we may use non-multilibbed uClibc toolchain but build U-Boot for
whatever ARC CPU flavour that current GCC supports

Private libgcc built from generic C implementation contributes only 144
bytes to .text section so we don't see significant degradation of size:
--->8---
$ arc-linux-size u-boot.libgcc-prebuilt
   text    data     bss     dec     hex filename
 222217   24912  214820  461949   70c7d u-boot.libgcc-prebuilt

$ arc-linux-size u-boot.libgcc-private
   text    data     bss     dec     hex filename
 222361   24912  214820  462093   70d0d u-boot.libgcc-private
--->8---

Also I don't notice visible performance degradation compared to
pre-built libgcc (where at least "*div*" functions are had-written in
assembly) on typical operations of downloading 10Mb uImage over TFTP and
bootm.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
arch/Kconfig
arch/arc/Kconfig
arch/arc/config.mk
arch/arc/lib/Makefile
arch/arc/lib/_millicodethunk.S [new file with mode: 0644]
arch/arc/lib/libgcc2.c [new file with mode: 0644]
arch/arc/lib/libgcc2.h [new file with mode: 0644]