summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRalph Holmes <ralph@ybden.com>2016-01-23 03:21:52 +0000
committerJoel Sherrill <joel@rtems.org>2016-01-22 21:27:00 -0600
commita0966605f3449a554a73b3ae6d9d9a6de2b175a0 (patch)
tree0e971e3e82e7a9503c1b2203ab2d5c895c5c68c4
parentm68k/gen68360: Add per-section compilation and linking support. (diff)
downloadrtems-a0966605f3449a554a73b3ae6d9d9a6de2b175a0.tar.bz2
m68k/mvme162: Add per-section compilation and linking support.
For the main BSP: The size of the sample executables without this option were: text data bss dec hex filename 85200 1632 11936 98768 181d0 base_sp.exe 100224 1600 11536 113360 1bad0 hello.exe 38432 1216 8016 47664 ba30 minimum.exe 536336 5552 23424 565312 8a040 fileio.exe 104192 1728 12048 117968 1ccd0 nsecs.exe 185520 2000 12528 200048 30d70 paranoia.exe 89424 1632 11968 103024 19270 ticker.exe 87984 1664 15376 105024 19a40 unlimited.exe 851456 21440 19008 891904 d9c00 cxx_iostream.exe 191872 2064 12080 206016 324c0 cdtest.exe 186288 2144 13760 202192 315d0 capture.exe The size of the sample executables with this option enabled were: text data bss dec hex filename 77600 1616 11888 91104 163e0 base_sp.exe 91824 1568 11472 104864 199a0 hello.exe 29856 1168 7952 38976 9840 minimum.exe 520432 5520 23088 549040 860b0 fileio.exe 97616 1712 11984 111312 1b2d0 nsecs.exe 177568 1984 12480 192032 2ee20 paranoia.exe 82560 1616 11904 96080 17750 ticker.exe 79760 1632 15312 96704 179c0 unlimited.exe 168256 2064 11728 182048 2c720 cxx_iostream.exe 176112 2000 12000 190112 2e6a0 cdtest.exe 176656 2096 13712 192464 2efd0 capture.exe For the mvme162lx BSP variant: The size of the sample executables without this option were: text data bss dec hex filename 85200 1632 11936 98768 181d0 base_sp.exe 100224 1600 11536 113360 1bad0 hello.exe 38432 1216 8016 47664 ba30 minimum.exe 536336 5552 23424 565312 8a040 fileio.exe 104192 1728 12048 117968 1ccd0 nsecs.exe 185520 2000 12528 200048 30d70 paranoia.exe 89424 1632 11968 103024 19270 ticker.exe 87984 1664 15376 105024 19a40 unlimited.exe 851456 21440 19008 891904 d9c00 cxx_iostream.exe 191872 2064 12080 206016 324c0 cdtest.exe 186288 2144 13760 202192 315d0 capture.exe The size of the sample executables with this option enabled were: text data bss dec hex filename 77600 1616 11888 91104 163e0 base_sp.exe 91824 1568 11472 104864 199a0 hello.exe 29856 1168 7952 38976 9840 minimum.exe 520432 5520 23088 549040 860b0 fileio.exe 97616 1712 11984 111312 1b2d0 nsecs.exe 177568 1984 12480 192032 2ee20 paranoia.exe 82560 1616 11904 96080 17750 ticker.exe 79760 1632 15312 96704 179c0 unlimited.exe 168256 2064 11728 182048 2c720 cxx_iostream.exe 176112 2000 12000 190112 2e6a0 cdtest.exe 176656 2096 13712 192464 2efd0 capture.exe
-rw-r--r--c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162.cfg3
-rw-r--r--c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162lx.cfg3
2 files changed, 6 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162.cfg b/c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162.cfg
index 4b343b2fe5..40bc4313b1 100644
--- a/c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162.cfg
+++ b/c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162.cfg
@@ -17,6 +17,9 @@ CPU_CFLAGS = -mcpu=68040 -msoft-float
# optimize flag: typically -O2
CFLAGS_OPTIMIZE_V = -O2 -g -fomit-frame-pointer
+CFLAGS_OPTIMIZE_V += -ffunction-sections -fdata-sections
+
+LDFLAGS = -Wl,--gc-sections
define bsp-post-link
$(default-bsp-post-link)
diff --git a/c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162lx.cfg b/c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162lx.cfg
index 2a210a9b92..06bea9c676 100644
--- a/c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162lx.cfg
+++ b/c/src/lib/libbsp/m68k/mvme162/make/custom/mvme162lx.cfg
@@ -22,6 +22,9 @@ CPU_CFLAGS = -mcpu=68040 -msoft-float
# optimize flag: typically -O2
CFLAGS_OPTIMIZE_V = -O2 -g -fomit-frame-pointer
+CFLAGS_OPTIMIZE_V += -ffunction-sections -fdata-sections
+
+LDFLAGS = -Wl,--gc-sections
define bsp-post-link
$(default-bsp-post-link)