diff options
author | Thiemo Seufer <ths@networkno.de> | 2004-04-23 17:25:50 +0000 |
---|---|---|
committer | Thiemo Seufer <ths@networkno.de> | 2004-04-23 17:25:50 +0000 |
commit | 81a21e382c59673f410292705491a086911a6a8b (patch) | |
tree | 21515982058c5cb306f996a808b2763b1624784e /gas | |
parent | 61bcae62f75a3075d4455ff3ba8204b50bfed75e (diff) | |
download | gdb-81a21e382c59673f410292705491a086911a6a8b.zip gdb-81a21e382c59673f410292705491a086911a6a8b.tar.gz gdb-81a21e382c59673f410292705491a086911a6a8b.tar.bz2 |
* config/tc-mips.c (s_mipsset): Set default CPU type for .set mipsN.
Diffstat (limited to 'gas')
-rw-r--r-- | gas/ChangeLog | 6 | ||||
-rw-r--r-- | gas/config/tc-mips.c | 40 |
2 files changed, 20 insertions, 26 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index 1aca510..f6d1721 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,4 +1,8 @@ -2004-04-22 Chris Demetriou <cgd@broadcom.com> +2004-04-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de> + + * config/tc-mips.c (s_mipsset): Set default CPU type for .set mipsN. + +2004-04-23 Chris Demetriou <cgd@broadcom.com> * config/tc-mips.c (md_longopts): Remove -membedded-pic option. (OPTION_MEMBEDDED_PIC): Remove. diff --git a/gas/config/tc-mips.c b/gas/config/tc-mips.c index a8b22f2..83d0296 100644 --- a/gas/config/tc-mips.c +++ b/gas/config/tc-mips.c @@ -11845,34 +11845,11 @@ s_mipsset (int x ATTRIBUTE_UNUSED) /* Permit the user to change the ISA and architecture on the fly. Needless to say, misuse can cause serious problems. */ - if (strcmp (name, "mips0") == 0) + if (strcmp (name, "mips0") == 0 || strcmp (name, "arch=default") == 0) { reset = 1; mips_opts.isa = file_mips_isa; - } - else if (strcmp (name, "mips1") == 0) - mips_opts.isa = ISA_MIPS1; - else if (strcmp (name, "mips2") == 0) - mips_opts.isa = ISA_MIPS2; - else if (strcmp (name, "mips3") == 0) - mips_opts.isa = ISA_MIPS3; - else if (strcmp (name, "mips4") == 0) - mips_opts.isa = ISA_MIPS4; - else if (strcmp (name, "mips5") == 0) - mips_opts.isa = ISA_MIPS5; - else if (strcmp (name, "mips32") == 0) - mips_opts.isa = ISA_MIPS32; - else if (strcmp (name, "mips32r2") == 0) - mips_opts.isa = ISA_MIPS32R2; - else if (strcmp (name, "mips64") == 0) - mips_opts.isa = ISA_MIPS64; - else if (strcmp (name, "mips64r2") == 0) - mips_opts.isa = ISA_MIPS64R2; - else if (strcmp (name, "arch=default") == 0) - { - reset = 1; mips_opts.arch = file_mips_arch; - mips_opts.isa = file_mips_isa; } else if (strncmp (name, "arch=", 5) == 0) { @@ -11887,8 +11864,21 @@ s_mipsset (int x ATTRIBUTE_UNUSED) mips_opts.isa = p->isa; } } + else if (strncmp (name, "mips", 4) == 0) + { + const struct mips_cpu_info *p; + + p = mips_parse_cpu("internal use", name); + if (!p) + as_bad (_("unknown ISA level %s"), name + 4); + else + { + mips_opts.arch = p->cpu; + mips_opts.isa = p->isa; + } + } else - as_bad (_("unknown ISA level %s"), name + 4); + as_bad (_("unknown ISA or architecture %s"), name); switch (mips_opts.isa) { |