[NDS32] Adjust ASM spec.
authorChung-Ju Wu <jasonwucj@gmail.com>
Sat, 19 May 2018 15:16:53 +0000 (15:16 +0000)
committerChung-Ju Wu <jasonwucj@gcc.gnu.org>
Sat, 19 May 2018 15:16:53 +0000 (15:16 +0000)
gcc/
* config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.

From-SVN: r260401

gcc/ChangeLog
gcc/config/nds32/nds32.h

index 97aa4e7..0bd395d 100644 (file)
@@ -1,5 +1,9 @@
 2018-05-19  Chung-Ju Wu  <jasonwucj@gmail.com>
 
+       * config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.
+
+2018-05-19  Chung-Ju Wu  <jasonwucj@gmail.com>
+
        * config/nds32/nds32.c
        (nds32_md_asm_adjust): Consider flag_inline_asm_r15 variable.
        * config/nds32/nds32.opt (minline-asm-r15): New option.
index 90b52d1..9ba5e17 100644 (file)
@@ -933,6 +933,10 @@ enum nds32_builtins
 #define ASM_SPEC \
   " %{mbig-endian:-EB} %{mlittle-endian:-EL}" \
   " %{march=*:-march=%*}" \
+  " %{mno-16-bit|mno-16bit:-mno-16bit-ext}" \
+  " %{march=v3m:%{!mfull-regs:%{!mreduced-regs:-mreduced-regs}}}" \
+  " %{mfull-regs:-mno-reduced-regs}" \
+  " %{mreduced-regs:-mreduced-regs}" \
   " %{mabi=*:-mabi=v%*}" \
   " %{mconfig-fpu=*:-mfpu-freg=%*}" \
   " %{mext-fpu-mac:-mmac}" \
@@ -941,7 +945,8 @@ enum nds32_builtins
   " %{mno-ext-fpu-sp:-mno-fpu-sp-ext}" \
   " %{mext-fpu-dp:-mfpu-dp-ext}" \
   " %{mno-ext-fpu-sp:-mno-fpu-dp-ext}" \
-  " %{mext-dsp:-mdsp-ext}"
+  " %{mext-dsp:-mdsp-ext}" \
+  " %{O|O1|O2|O3|Ofast:-O1;:-Os}"
 
 /* If user issues -mrelax, we need to pass '--relax' to linker.  */
 #define LINK_SPEC \