Commit 0b8d13fb authored by Matthias Braun's avatar Matthias Braun
Browse files

Let backends indicate whether they support thread local storage

parent 5224ed3c
......@@ -104,6 +104,8 @@ typedef struct backend_params {
/** unaligned memory accesses are not supported natively (but the backend
* may break the access up into several smaller ones) */
unsigned unaligned_memaccess_supported:1;
/** Whether thread local storage is supported. */
unsigned thread_local_storage_supported:1;
/**
* Shifts on this architecture only read some bits of the shift value.
......
......@@ -1382,20 +1382,21 @@ static const ir_settings_arch_dep_t ia32_arch_dep = {
.max_bits_for_mulh = 32,
};
static backend_params ia32_backend_params = {
.byte_order_big_endian = false,
.pic_supported = true,
.unaligned_memaccess_supported = true,
.modulo_shift = 32,
.dep_param = &ia32_arch_dep,
.allow_ifconv = ia32_is_mux_allowed,
.machine_size = 32,
.mode_float_arithmetic = NULL, /* will be set later */
.type_long_long = NULL, /* will be set later */
.type_unsigned_long_long = NULL, /* will be set later */
.type_long_double = NULL, /* will be set later */
.stack_param_align = 4,
.float_int_overflow = ir_overflow_indefinite,
.vararg = {
.byte_order_big_endian = false,
.pic_supported = true,
.unaligned_memaccess_supported = true,
.thread_local_storage_supported = true,
.modulo_shift = 32,
.dep_param = &ia32_arch_dep,
.allow_ifconv = ia32_is_mux_allowed,
.machine_size = 32,
.mode_float_arithmetic = NULL, /* will be set later */
.type_long_long = NULL, /* will be set later */
.type_unsigned_long_long = NULL, /* will be set later */
.type_long_double = NULL, /* will be set later */
.stack_param_align = 4,
.float_int_overflow = ir_overflow_indefinite,
.vararg = {
.va_list_type = NULL, /* will be set later */
.lower_va_arg = be_default_lower_va_arg,
},
......
......@@ -524,20 +524,21 @@ static const backend_params *sparc_get_backend_params(void)
.max_bits_for_mulh = 32,
};
static backend_params p = {
.byte_order_big_endian = true,
.pic_supported = false,
.unaligned_memaccess_supported = false,
.modulo_shift = 32,
.dep_param = &arch_dep,
.allow_ifconv = sparc_is_mux_allowed,
.machine_size = 32,
.mode_float_arithmetic = NULL, /* will be set later */
.type_long_long = NULL, /* will be set later */
.type_unsigned_long_long = NULL, /* will be set later */
.type_long_double = NULL, /* will be set later */
.stack_param_align = 4,
.float_int_overflow = ir_overflow_min_max,
.vararg = {
.byte_order_big_endian = true,
.pic_supported = false,
.unaligned_memaccess_supported = false,
.thread_local_storage_supported = true,
.modulo_shift = 32,
.dep_param = &arch_dep,
.allow_ifconv = sparc_is_mux_allowed,
.machine_size = 32,
.mode_float_arithmetic = NULL, /* will be set later */
.type_long_long = NULL, /* will be set later */
.type_unsigned_long_long = NULL, /* will be set later */
.type_long_double = NULL, /* will be set later */
.stack_param_align = 4,
.float_int_overflow = ir_overflow_min_max,
.vararg = {
.va_list_type = NULL, /* will be set later */
.lower_va_arg = be_default_lower_va_arg,
},
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment