int xchal_have_xea3;
};
+struct xtensa_config_v4
+{
+ int xchal_data_width;
+ int xchal_unaligned_load_exception;
+ int xchal_unaligned_store_exception;
+ int xchal_unaligned_load_hw;
+ int xchal_unaligned_store_hw;
+};
+
extern const void *xtensa_load_config (const char *name,
const void *no_plugin_def,
const void *no_name_def);
extern const struct xtensa_config_v1 *xtensa_get_config_v1 (void);
extern const struct xtensa_config_v2 *xtensa_get_config_v2 (void);
extern const struct xtensa_config_v3 *xtensa_get_config_v3 (void);
+extern const struct xtensa_config_v4 *xtensa_get_config_v4 (void);
#ifdef XTENSA_CONFIG_DEFINITION
#define XCHAL_HAVE_XEA3 0
#endif
+#ifndef XCHAL_DATA_WIDTH
+#define XCHAL_DATA_WIDTH 16
+#endif
+
+#ifndef XCHAL_UNALIGNED_LOAD_EXCEPTION
+#define XCHAL_UNALIGNED_LOAD_EXCEPTION 1
+#endif
+
+#ifndef XCHAL_UNALIGNED_STORE_EXCEPTION
+#define XCHAL_UNALIGNED_STORE_EXCEPTION 1
+#endif
+
+#ifndef XCHAL_UNALIGNED_LOAD_HW
+#define XCHAL_UNALIGNED_LOAD_HW 0
+#endif
+
+#ifndef XCHAL_UNALIGNED_STORE_HW
+#define XCHAL_UNALIGNED_STORE_HW 0
+#endif
+
#define XTENSA_CONFIG_ENTRY(a) a
#define XTENSA_CONFIG_V1_ENTRY_LIST \
XTENSA_CONFIG_ENTRY(XCHAL_HAVE_EXCLUSIVE), \
XTENSA_CONFIG_ENTRY(XCHAL_HAVE_XEA3)
+#define XTENSA_CONFIG_V4_ENTRY_LIST \
+ XTENSA_CONFIG_ENTRY(XCHAL_DATA_WIDTH), \
+ XTENSA_CONFIG_ENTRY(XCHAL_UNALIGNED_LOAD_EXCEPTION), \
+ XTENSA_CONFIG_ENTRY(XCHAL_UNALIGNED_STORE_EXCEPTION), \
+ XTENSA_CONFIG_ENTRY(XCHAL_UNALIGNED_LOAD_HW), \
+ XTENSA_CONFIG_ENTRY(XCHAL_UNALIGNED_STORE_HW)
+
#define XTENSA_CONFIG_INSTANCE_LIST \
const struct xtensa_config_v1 xtensa_config_v1 = { \
XTENSA_CONFIG_V1_ENTRY_LIST, \
}; \
const struct xtensa_config_v3 xtensa_config_v3 = { \
XTENSA_CONFIG_V3_ENTRY_LIST, \
+}; \
+const struct xtensa_config_v4 xtensa_config_v4 = { \
+ XTENSA_CONFIG_V4_ENTRY_LIST, \
}
#define XTENSA_CONFIG_ENTRY_LIST \
XTENSA_CONFIG_V1_ENTRY_LIST, \
XTENSA_CONFIG_V2_ENTRY_LIST, \
- XTENSA_CONFIG_V3_ENTRY_LIST
+ XTENSA_CONFIG_V3_ENTRY_LIST, \
+ XTENSA_CONFIG_V4_ENTRY_LIST
#else /* XTENSA_CONFIG_DEFINITION */
#undef XCHAL_HAVE_XEA3
#define XCHAL_HAVE_XEA3 (xtensa_get_config_v3 ()->xchal_have_xea3)
+
+#undef XCHAL_DATA_WIDTH
+#define XCHAL_DATA_WIDTH (xtensa_get_config_v4 ()->xchal_data_width)
+
+#undef XCHAL_UNALIGNED_LOAD_EXCEPTION
+#define XCHAL_UNALIGNED_LOAD_EXCEPTION (xtensa_get_config_v4 ()->xchal_unaligned_load_exception)
+
+#undef XCHAL_UNALIGNED_STORE_EXCEPTION
+#define XCHAL_UNALIGNED_STORE_EXCEPTION (xtensa_get_config_v4 ()->xchal_unaligned_store_exception)
+
+#undef XCHAL_UNALIGNED_LOAD_HW
+#define XCHAL_UNALIGNED_LOAD_HW (xtensa_get_config_v4 ()->xchal_unaligned_load_hw)
+
+#undef XCHAL_UNALIGNED_STORE_HW
+#define XCHAL_UNALIGNED_STORE_HW (xtensa_get_config_v4 ()->xchal_unaligned_store_hw)
+
#endif /* XTENSA_CONFIG_DEFINITION */
#ifdef __cplusplus