Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Zwinkau
libfirm
Commits
60fbd0c3
Commit
60fbd0c3
authored
Aug 19, 2015
by
Christoph Mallon
Browse files
bescripts: Clean up the node generator script a bit more.
parent
2e3dd0af
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/be/scripts/generate_new_opcodes.pl
View file @
60fbd0c3
...
...
@@ -427,11 +427,7 @@ static inline bool is_$op(ir_node const *const n)
EOF
my
$attr_type
=
$n
{
attr_type
};
if
(
!
defined
(
$attr_type
))
{
$attr_type
=
$default_attr_type
;
$n
{
attr_type
}
=
$attr_type
;
}
my
$attr_type
=
$n
{
attr_type
}
//
=
$default_attr_type
;
my
%constructors
;
if
(
exists
(
$n
{
constructors
}))
{
...
...
@@ -479,13 +475,10 @@ EOF
$op_flags_joined
=
"
irop_flag_none
";
}
my
$attr_size
=
"
0
";
if
(
$attr_type
ne
"")
{
$attr_size
=
"
sizeof(
$attr_type
)
"
}
my
$state
=
$n
{
state
}
//
"
floats
";
$obst_new_irop
.=
"
\t
op = new_ir_op(cur_opcode + iro_
$op
,
\"
$op
\"
, op_pin_state_
$state
,
$op_flags_joined
,
"
.
translate_arity
(
$arity
)
.
"
, -1,
$attr_size
);
\n
";
my
$state
=
$n
{
state
}
//
"
floats
";
my
$op_arity
=
translate_arity
(
$arity
);
my
$attr_size
=
$attr_type
ne
""
?
"
sizeof(
$attr_type
)
"
:
"
0
";
$obst_new_irop
.=
"
\t
op = new_ir_op(cur_opcode + iro_
$op
,
\"
$op
\"
, op_pin_state_
$state
,
$op_flags_joined
,
$op_arity
, -1,
$attr_size
);
\n
";
my
$dump_func
=
$n
{
dump_func
}
//
"
${arch}
_dump_node
";
$obst_new_irop
.=
"
\t
set_op_dump(op,
$dump_func
);
\n
";
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment