X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fbe%2FTEMPLATE%2FTEMPLATE_spec.pl;h=17b590d6c3aba3d00d728f186198e78b8e6a6046;hb=b4cf865778f8aeb6acd2a7f98dc3817e942271cc;hp=45833aad0d491c8bae923fa7d7a26d557352c7a8;hpb=863d31d7a5c8210432fef88b30fc3e8353131538;p=libfirm diff --git a/ir/be/TEMPLATE/TEMPLATE_spec.pl b/ir/be/TEMPLATE/TEMPLATE_spec.pl index 45833aad0..17b590d6c 100644 --- a/ir/be/TEMPLATE/TEMPLATE_spec.pl +++ b/ir/be/TEMPLATE/TEMPLATE_spec.pl @@ -14,20 +14,28 @@ $arch = "TEMPLATE"; # %nodes = ( # # => { -# op_flags => "N|L|C|X|I|F|Y|H|c|K", -# irn_flags => "R|N|I" -# arity => "0|1|2|3 ... |variable|dynamic|any", -# state => "floats|pinned|mem_pinned|exc_pinned", +# op_flags => "N|L|C|X|I|F|Y|H|c|K", # optional +# irn_flags => "R|N|I" # optional +# arity => "0|1|2|3 ... |variable|dynamic|any", # optional +# state => "floats|pinned|mem_pinned|exc_pinned", # optional # args => [ # { type => "type 1", name => "name 1" }, # { type => "type 2", name => "name 2" }, # ... # ], -# comment => "any comment for constructor", +# comment => "any comment for constructor", # optional # reg_req => { in => [ "reg_class|register" ], out => [ "reg_class|register|in_rX" ] }, -# cmp_attr => "c source code for comparing node attributes", -# emit => "emit code with templates", -# rd_constructor => "c source code which constructs an ir_node" +# cmp_attr => "c source code for comparing node attributes", # optional +# outs => { "out1", "out2" },# optional, creates pn_op_out1, ... consts +# ins => { "in1", "in2" }, # optional, creates n_op_in1, ... consts +# mode => "mode_Iu", # optional, predefines the mode +# emit => "emit code with templates", # optional for virtual nodes +# attr => "additional attribute arguments for constructor", # optional +# init_attr => "emit attribute initialization template", # optional +# rd_constructor => "c source code which constructs an ir_node", # optional +# hash_func => "name of the hash function for this operation", # optional, get the default hash function else +# latency => "latency of this operation (can be float)" # optional +# attr_type => "name of the attribute struct", # optional # }, # # ... # (all nodes you need to describe) @@ -133,19 +141,19 @@ $arch = "TEMPLATE"; ); # %reg_classes %emit_templates = ( - S1 => "${arch}_emit_source_register(env, node, 0);", - S2 => "${arch}_emit_source_register(env, node, 1);", - S3 => "${arch}_emit_source_register(env, node, 2);", - S4 => "${arch}_emit_source_register(env, node, 3);", - S5 => "${arch}_emit_source_register(env, node, 4);", - S6 => "${arch}_emit_source_register(env, node, 5);", - D1 => "${arch}_emit_dest_register(env, node, 0);", - D2 => "${arch}_emit_dest_register(env, node, 1);", - D3 => "${arch}_emit_dest_register(env, node, 2);", - D4 => "${arch}_emit_dest_register(env, node, 3);", - D5 => "${arch}_emit_dest_register(env, node, 4);", - D6 => "${arch}_emit_dest_register(env, node, 5);", - C => "${arch}_emit_immediate(env, node);" + S1 => "${arch}_emit_source_register(node, 0);", + S2 => "${arch}_emit_source_register(node, 1);", + S3 => "${arch}_emit_source_register(node, 2);", + S4 => "${arch}_emit_source_register(node, 3);", + S5 => "${arch}_emit_source_register(node, 4);", + S6 => "${arch}_emit_source_register(node, 5);", + D1 => "${arch}_emit_dest_register(node, 0);", + D2 => "${arch}_emit_dest_register(node, 1);", + D3 => "${arch}_emit_dest_register(node, 2);", + D4 => "${arch}_emit_dest_register(node, 3);", + D5 => "${arch}_emit_dest_register(node, 4);", + D6 => "${arch}_emit_dest_register(node, 5);", + C => "${arch}_emit_immediate(node);" ); #--------------------------------------------------#