#endif
#define MINI_OP(a,b) b,
/* keep in sync with the enum in mini.h */
-static const char*
+static const char* const
opnames[] = {
#include "mini-ops.h"
};
if (op >= OP_LOAD && op <= OP_LAST)
return opnames [op - OP_LOAD];
if (op < OP_LOAD)
- return mono_opcode_names [op];
+ return mono_opcode_name (op);
g_error ("unknown opcode name for %d", op);
return NULL;
}
fclose (ofd);
#ifdef __APPLE__
-#define DIS_CMD "otool -V -v -t"
+#define DIS_CMD "otool -v -t"
#else
#if defined(sparc) && !defined(__GNUC__)
#define DIS_CMD "dis"
#define DIS_CMD "objdump -d"
#endif
#endif
+#if defined(sparc)
+#define AS_CMD "as -xarch=v9"
+#else
+#define AS_CMD "as"
+#endif
+
o_file = g_strdup_printf ("%s/test.o", tmp);
- cmd = g_strdup_printf ("as %s -o %s", as_file, o_file);
+ cmd = g_strdup_printf (AS_CMD " %s -o %s", as_file, o_file);
system (cmd);
g_free (cmd);
if (!objdump_args)