summaryrefslogtreecommitdiffstats
path: root/c/src
diff options
context:
space:
mode:
authorJoel Sherrill <joel@rtems.org>2016-01-05 17:21:59 -0600
committerJoel Sherrill <joel@rtems.org>2016-01-05 17:34:29 -0600
commitbd655345c1a5f7dba42ddf6cd56f6259c62eb267 (patch)
treed452b748950de80dd5e3398ed1974bd885831260 /c/src
parentjmr3904.cfg: Delete old comments (diff)
downloadrtems-bd655345c1a5f7dba42ddf6cd56f6259c62eb267.tar.bz2
mips/jmr3904: Add per-section compilation and linking support
The size of the sample executables without this option were: 128028 1812 12224 142064 22af0 ticker.exe 52600 1324 8192 62116 f2a4 minimum.exe 1156240 2168 19696 1178104 11f9f8 cxx_iostream.exe 706952 5908 24600 737460 b40b4 fileio.exe 243232 2372 14084 259688 3f668 capture.exe 155660 1940 12376 169976 297f8 nsecs.exe 201256 2212 12896 216364 34d2c paranoia.exe 253696 1872 12576 268144 41770 cdtest.exe 124452 1812 12208 138472 21ce8 base_sp.exe 127640 1844 15648 145132 236ec unlimited.exe 133452 1780 11760 146992 23e30 hello.exe The size of the sample executables with this option enabled were: 115052 1712 12096 128860 1f75c ticker.exe 40760 1256 8144 50160 c3f0 minimum.exe 671768 2076 18688 692532 a9134 cxx_iostream.exe 679672 5696 23992 709360 ad2f0 fileio.exe 227384 2196 13924 243504 3b730 capture.exe 143132 1832 12248 157212 2661c nsecs.exe 187736 2104 12768 202608 31770 paranoia.exe 234324 1788 12448 248560 3caf0 cdtest.exe 111556 1712 12080 125348 1e9a4 base_sp.exe 112876 1744 15520 130140 1fc5c unlimited.exe 118120 1688 11696 131504 201b0 hello.exe
Diffstat (limited to 'c/src')
-rw-r--r--c/src/lib/libbsp/mips/jmr3904/make/custom/jmr3904.cfg5
1 files changed, 5 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/mips/jmr3904/make/custom/jmr3904.cfg b/c/src/lib/libbsp/mips/jmr3904/make/custom/jmr3904.cfg
index 056f63c93f..6b761356da 100644
--- a/c/src/lib/libbsp/mips/jmr3904/make/custom/jmr3904.cfg
+++ b/c/src/lib/libbsp/mips/jmr3904/make/custom/jmr3904.cfg
@@ -10,3 +10,8 @@ RTEMS_CPU_MODEL=tx3904
CPU_CFLAGS = -march=r3900 -Wa,-xgot -G0
CFLAGS_OPTIMIZE_V = -O2 -g
+
+# arguments to compile and link with per-element sections
+CFLAGS_OPTIMIZE_V += -ffunction-sections -fdata-sections
+LDFLAGS = -Wl,--gc-sections
+