* config/tc-mips.c (md_parse_option): Match mips_optimize to the -O
authorThiemo Seufer <ths@networkno.de>
Sat, 17 Nov 2007 14:19:19 +0000 (14:19 +0000)
committerThiemo Seufer <ths@networkno.de>
Sat, 17 Nov 2007 14:19:19 +0000 (14:19 +0000)
option supplied, but still keep mips_optimize == 2 as default value.

gas/ChangeLog
gas/config/tc-mips.c

index 0a182bf..6604e8e 100644 (file)
@@ -1,5 +1,10 @@
 2007-11-17  Thiemo Seufer  <ths@mips.com>
 
+       * config/tc-mips.c (md_parse_option): Match mips_optimize to the -O
+       option supplied, but still keep mips_optimize == 2 as default value.
+
+2007-11-17  Thiemo Seufer  <ths@mips.com>
+
        * doc/as.texinfo: Document the new attribute value.
 
 2007-11-16  Eric B. Weddington  <eric.weddington@atmel.com>
index 722c47e..dfc1646 100644 (file)
@@ -11013,7 +11013,11 @@ md_parse_option (int c, char *arg)
       break;
 
     case 'O':
-      if (arg && arg[0] == '0')
+      if (arg == NULL)
+       mips_optimize = 1;
+      else if (arg[0] == '0')
+       mips_optimize = 0;
+      else if (arg[0] == '1')
        mips_optimize = 1;
       else
        mips_optimize = 2;