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
d6624b6e
Commit
d6624b6e
authored
May 06, 2013
by
Matthias Braun
Browse files
simplify+fix is_arch_XXX() functions
parent
3cfc2618
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/be/scripts/generate_new_opcodes.pl
View file @
d6624b6e
...
...
@@ -542,13 +542,13 @@ foreach my $op (keys(%nodes)) {
# Create opcode
$obst_opvar
.=
"
ir_op *op_
$op
= NULL;
\n
";
$obst_get_opvar
.=
"
ir_op *get_op_
$op
(void) { return op_
$op
; }
\n
";
$obst_get_opvar
.=
"
int is_
$op
(const ir_node *n) { return get_
$arch
\
_irn_opcode(n) == iro_
$op
; }
\n\n
";
$obst_get_opvar
.=
"
bool is_
$op
(const ir_node *n) {
\n
";
$obst_get_opvar
.=
"
\t
return get_irn_op(n) == op_
$op
;
\n
";
$obst_get_opvar
.=
"
}
\n\n
";
$obst_header
.=
<<EOF;
extern ir_op *op_${op};
ir_op *get_op_${op}(void);
int is_${op}(const ir_node *n);
bool is_${op}(const ir_node *n);
EOF
my
$attr_type
=
$n
{
attr_type
};
...
...
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