MonoAotOptions aot_opts;
guint32 nmethods;
guint32 opts;
+ guint32 simd_opts;
MonoMemPool *mempool;
MonoAotStats stats;
int method_index;
emit_int32 (acfg, acfg->nmethods);
emit_int32 (acfg, acfg->flags);
emit_int32 (acfg, acfg->opts);
+ emit_int32 (acfg, acfg->simd_opts);
emit_int32 (acfg, gc_name_offset);
for (i = 0; i < MONO_AOT_TRAMP_NUM; ++i)
acfg->globals = g_ptr_array_new ();
acfg->image = image;
acfg->opts = opts;
+ /* TODO: Write out set of SIMD instructions used, rather than just those available */
+ acfg->simd_opts = mono_arch_cpu_enumerate_simd_versions ();
acfg->mempool = mono_mempool_new ();
acfg->extra_methods = g_ptr_array_new ();
acfg->unwind_info_offsets = g_hash_table_new (NULL, NULL);
usable = FALSE;
}
+ if (info->simd_opts & ~mono_arch_cpu_enumerate_simd_versions ()) {
+ msg = g_strdup_printf ("compiled with unsupported SIMD extensions");
+ usable = FALSE;
+ }
+
blob = info->blob;
if (info->gc_name_index != -1) {
}
/*========================= End of Function ========================*/
+/*------------------------------------------------------------------*/
+/* */
+/* Name - mono_arch_cpu_enumerate_simd_versions */
+/* */
+/* Function - Returns the SIMD instruction sets on this CPU */
+/* */
+/*------------------------------------------------------------------*/
+guint32
+mono_arch_cpu_enumerate_simd_versions (void)
+{
+ /* SIMD is currently unimplemented */
+ return 0;
+}
+/*========================= End of Function ========================*/
+
+
+
/*------------------------------------------------------------------*/
/* */
/* Name - mono_arch_flush_icache */
return opts;
}
+/*
+ * This function test for all SIMD functions supported.
+ *
+ * Returns a bitmask corresponding to all supported versions.
+ *
+ */
+guint32
+mono_arch_cpu_enumerate_simd_versions (void)
+{
+ /* SIMD is currently unimplemented */
+ return 0;
+}
+
+
#ifndef DISABLE_JIT
static gboolean
return opts;
}
+/*
+ * This function test for all SIMD functions supported.
+ *
+ * Returns a bitmask corresponding to all supported versions.
+ *
+ */
+guint32
+mono_arch_cpu_enumerate_simd_versions (void)
+{
+ /* SIMD is currently unimplemented */
+ return 0;
+}
+
void
mono_arch_flush_icache (guint8 *code, gint size)
{
return 0;
}
+/*
+ * This function test for all SIMD functions supported.
+ *
+ * Returns a bitmask corresponding to all supported versions.
+ *
+ */
+guint32
+mono_arch_cpu_enumerate_simd_versions (void)
+{
+ /* SIMD is currently unimplemented */
+ return 0;
+}
+
GList *
mono_arch_get_allocatable_int_vars (MonoCompile *cfg)
{
return opts;
}
+/*
+ * This function test for all SIMD functions supported.
+ *
+ * Returns a bitmask corresponding to all supported versions.
+ *
+ */
+guint32
+mono_arch_cpu_enumerate_simd_versions (void)
+{
+ /* SIMD is currently unimplemented */
+ return 0;
+}
+
GList *
mono_arch_get_allocatable_int_vars (MonoCompile *cfg)
{
return opts;
}
+/*
+ * This function test for all SIMD functions supported.
+ *
+ * Returns a bitmask corresponding to all supported versions.
+ *
+ */
+guint32
+mono_arch_cpu_enumerate_simd_versions (void)
+{
+ /* SIMD is currently unimplemented */
+ return 0;
+}
+
#ifdef __mono_ppc64__
#define CASE_PPC32(c)
#define CASE_PPC64(c) case c:
/*========================= End of Function ========================*/
+/*------------------------------------------------------------------*/
+/* */
+/* Name - mono_arch_cpu_enumerate_simd_versions */
+/* */
+/* Function - Returns the SIMD instruction sets on this CPU */
+/* */
+/*------------------------------------------------------------------*/
+guint32
+mono_arch_cpu_enumerate_simd_versions (void)
+{
+ /* SIMD is currently unimplemented */
+ return 0;
+}
+/*========================= End of Function ========================*/
+
/*------------------------------------------------------------------*/
/* */
/* Name - */
/*========================= End of Function ========================*/
+/*------------------------------------------------------------------*/
+/* */
+/* Name - mono_arch_cpu_enumerate_simd_versions */
+/* */
+/* Function - Returns the SIMD instruction sets on this CPU */
+/* */
+/*------------------------------------------------------------------*/
+guint32
+mono_arch_cpu_enumerate_simd_versions (void)
+{
+ /* SIMD is currently unimplemented */
+ return 0;
+}
+/*========================= End of Function ========================*/
+
/*------------------------------------------------------------------*/
/* */
/* Name - */
return opts;
}
+/*
+ * This function test for all SIMD functions supported.
+ *
+ * Returns a bitmask corresponding to all supported versions.
+ *
+ */
+guint32
+mono_arch_cpu_enumerate_simd_versions (void)
+{
+ /* SIMD is currently unimplemented */
+ return 0;
+}
+
#ifdef __GNUC__
#define flushi(addr) __asm__ __volatile__ ("iflush %0"::"r"(addr):"memory")
#else /* assume Sun's compiler */
#endif
/* Version number of the AOT file format */
-#define MONO_AOT_FILE_VERSION 82
+#define MONO_AOT_FILE_VERSION 83
//TODO: This is x86/amd64 specific.
#define mono_simd_shuffle_mask(a,b,c,d) ((a) | ((b) << 2) | ((c) << 4) | ((d) << 6))
guint32 flags;
/* Optimization flags used to compile the module */
guint32 opts;
+ /* SIMD flags used to compile the module */
+ guint32 simd_opts;
/* Index of the blob entry holding the GC used by this module */
gint32 gc_name_index;