From: Jozef Lawrynowicz Date: Wed, 30 Aug 2017 09:33:56 +0000 (+0000) Subject: msp430.h: Pass -mcode/data-region to the linker and -mdata-region to the assembler. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=39459216fcf68c21e692e9a18797e3dc764b023f;p=gcc.git msp430.h: Pass -mcode/data-region to the linker and -mdata-region to the assembler. * gcc/config/msp430/msp430.h: Pass -mcode/data-region to the linker and -mdata-region to the assembler. From-SVN: r251449 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1879507fd7d..407b0254b0c 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2017-08-30 Jozef Lawrynowicz + + * gcc/config/msp430/msp430.h: Pass -mcode/data-region to the linker + and -mdata-region to the assembler. + 2017-08-30 Richard Biener * dwarf2out.c (add_dwarf_attr): Check we don't add duplicate diff --git a/gcc/config/msp430/msp430.h b/gcc/config/msp430/msp430.h index 2bff249e9ae..e95106dd01c 100644 --- a/gcc/config/msp430/msp430.h +++ b/gcc/config/msp430/msp430.h @@ -58,12 +58,14 @@ extern bool msp430x; "%{!msim:-md} %{msim:%{mlarge:-md}} " /* Copy data from ROM to RAM if necessary. */ \ "%{msilicon-errata=*:-msilicon-errata=%*} " /* Pass on -msilicon-errata. */ \ "%{msilicon-errata-warn=*:-msilicon-errata-warn=%*} " /* Pass on -msilicon-errata-warn. */ \ - "%{ffunction-sections:-gdwarf-sections} " /* If function sections are being created then create DWARF line number sections as well. */ + "%{ffunction-sections:-gdwarf-sections} " /* If function sections are being created then create DWARF line number sections as well. */ \ + "%{mdata-region=*:-mdata-region=%*} " /* Pass on -mdata-region. */ /* Enable linker section garbage collection by default, unless we are creating a relocatable binary (gc does not work) or debugging is enabled (the GDB testsuite relies upon unused entities not being deleted). */ -#define LINK_SPEC "%{mrelax:--relax} %{mlarge:%{!r:%{!g:--gc-sections}}}" +#define LINK_SPEC "%{mrelax:--relax} %{mlarge:%{!r:%{!g:--gc-sections}}} " \ + "%{mcode-region=*:--code-region=%*} %{mdata-region=*:--data-region=%*}" extern const char * msp430_select_hwmult_lib (int, const char **); # define EXTRA_SPEC_FUNCTIONS \