@@ -9877,6 +9877,40 @@ mips_mdebug_abi_name (void)
}
}
+static const char *
+mips_module_isa_name()
+{
+ if (ISA_MIPS1)
+ return "mips1";
+ else if (ISA_MIPS2)
+ return "mips2";
+ else if (ISA_MIPS3)
+ return "mips3";
+ else if (ISA_MIPS4)
+ return "mips4";
+ else if (ISA_MIPS32)
+ return "mips32";
+ else if (ISA_MIPS32R2)
+ return "mips32r2";
+ else if (ISA_MIPS32R3)
+ return "mips32R3";
+ else if (ISA_MIPS32R5)
+ return "mips32r5";
+ else if (ISA_MIPS32R6)
+ return "mips32r6";
+ else if (ISA_MIPS64)
+ return "mips64";
+ else if (ISA_MIPS64R2)
+ return "mips64r2";
+ else if (ISA_MIPS64R3)
+ return "mips64R3";
+ else if (ISA_MIPS64R5)
+ return "mips64r5";
+ else if (ISA_MIPS64R6)
+ return "mips64r6";
+ gcc_unreachable ();
+}
+
/* Implement TARGET_ASM_FILE_START. */
static void
@@ -9908,6 +9942,9 @@ mips_file_start (void)
fprintf (asm_out_file, "\t.nan\t%s\n",
mips_nan == MIPS_IEEE_754_2008 ? "2008" : "legacy");
+ fprintf (asm_out_file, "\t.module\t%s\n",
+ mips_module_isa_name ());
+
#ifdef HAVE_AS_DOT_MODULE
/* Record the FP ABI. See below for comments. */
if (TARGET_NO_FLOAT)