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
e4654328
Commit
e4654328
authored
Jul 11, 2007
by
Michael Beck
Browse files
simplified code
[r15026]
parent
2ea7f634
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/be/bechordal.c
View file @
e4654328
...
...
@@ -668,23 +668,24 @@ static ir_node *handle_constraints(be_chordal_alloc_env_t *alloc_env,
/* Assign colors obtained from the matching. */
for
(
i
=
0
;
i
<
n_alloc
;
++
i
)
{
const
arch_register_t
*
reg
;
ir_node
*
nodes
[
2
];
int
j
;
ir_node
*
irn
;
assert
(
assignment
[
i
]
>=
0
&&
"there must have been a register assigned"
);
reg
=
arch_register_for_index
(
env
->
cls
,
assignment
[
i
]);
assert
(
!
(
reg
->
type
&
arch_register_type_ignore
));
nodes
[
0
]
=
alloc_nodes
[
i
];
nodes
[
1
]
=
pmap_get
(
partners
,
alloc_nodes
[
i
]);
for
(
j
=
0
;
j
<
2
;
++
j
)
{
if
(
!
nodes
[
j
])
continue
;
irn
=
alloc_nodes
[
i
];
if
(
irn
!=
NULL
)
{
arch_set_irn_register
(
aenv
,
irn
,
reg
);
(
void
)
pset_hinsert_ptr
(
alloc_env
->
pre_colored
,
irn
);
DBG
((
dbg
,
LEVEL_2
,
"
\t
setting %+F to register %s
\n
"
,
irn
,
reg
->
name
));
}
assert
(
!
(
reg
->
type
&
arch_register_type_ignore
));
arch_set_irn_register
(
aenv
,
nodes
[
j
],
reg
);
(
void
)
pset_hinsert_ptr
(
alloc_env
->
pre_colored
,
nodes
[
j
]);
DBG
((
dbg
,
LEVEL_2
,
"
\t
setting %+F to register %s
\n
"
,
nodes
[
j
],
reg
->
name
));
irn
=
pmap_get
(
partners
,
alloc_nodes
[
i
]);
if
(
irn
!=
NULL
)
{
arch_set_irn_register
(
aenv
,
irn
,
reg
);
(
void
)
pset_hinsert_ptr
(
alloc_env
->
pre_colored
,
irn
);
DBG
((
dbg
,
LEVEL_2
,
"
\t
setting %+F to register %s
\n
"
,
irn
,
reg
->
name
));
}
}
...
...
Write
Preview
Supports
Markdown
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