summaryrefslogtreecommitdiffhomepage
path: root/ir/ir
diff options
context:
space:
mode:
authorChristoph Mallon <christoph.mallon@gmx.de>2016-07-08 20:07:33 +0200
committerChristoph Mallon <christoph.mallon@gmx.de>2016-07-11 14:40:44 +0200
commit1a643e44900c511a733d977d9d31de036ea2b4f9 (patch)
tree0cf620d31407007a8b76eb8e41c9513bbce009a3 /ir/ir
parentcc80f54ffafd48a98732d0196265bd08ef790703 (diff)
Set the additional properties right when construction a method type.
Diffstat (limited to 'ir/ir')
-rw-r--r--ir/ir/irio.c3
-rw-r--r--ir/ir/irprofile.c4
2 files changed, 3 insertions, 4 deletions
diff --git a/ir/ir/irio.c b/ir/ir/irio.c
index fd3608a..df022c0 100644
--- a/ir/ir/irio.c
+++ b/ir/ir/irio.c
@@ -1634,7 +1634,7 @@ static void read_type(read_env_t *env)
size_t const nparams = read_size_t(env);
size_t const nresults = read_size_t(env);
bool const is_variadic = read_long(env);
- type = new_type_method(nparams, nresults, is_variadic, callingconv);
+ type = new_type_method(nparams, nresults, is_variadic, callingconv, addprops);
for (size_t i = 0; i < nparams; i++) {
long ptypenr = read_long(env);
@@ -1649,7 +1649,6 @@ static void read_type(read_env_t *env)
set_method_res_type(type, i, restype);
}
- set_method_additional_properties(type, addprops);
goto finish_type;
}
diff --git a/ir/ir/irprofile.c b/ir/ir/irprofile.c
index 05535b5..f995f44 100644
--- a/ir/ir/irprofile.c
+++ b/ir/ir/irprofile.c
@@ -152,7 +152,7 @@ static void add_constructor(ir_entity *method)
static ir_entity *get_init_firmprof_ref(void)
{
ident *const init_name = new_id_from_str("__init_firmprof");
- ir_type *const init_type = new_type_method(3, 0, false, cc_cdecl_set);
+ ir_type *const init_type = new_type_method(3, 0, false, cc_cdecl_set, mtp_no_property);
ir_type *const uint = get_type_for_mode(mode_Iu);
ir_type *const uintptr = new_type_pointer(uint);
ir_type *const string = new_type_pointer(get_type_for_mode(mode_Bs));
@@ -177,7 +177,7 @@ static ir_graph *gen_initializer_irg(ir_entity *ent_filename, ir_entity *bblock_
{
ident *const name = new_id_from_str("__firmprof_initializer");
ir_type *const owner = get_glob_type();
- ir_type *const type = new_type_method(0, 0, false, cc_cdecl_set);
+ ir_type *const type = new_type_method(0, 0, false, cc_cdecl_set, mtp_no_property);
ir_entity *const ent = new_global_entity(owner, name, type, ir_visibility_local, IR_LINKAGE_DEFAULT);
ir_graph *const irg = new_ir_graph(ent, 0);