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
ecfcdc3a
Commit
ecfcdc3a
authored
Dec 15, 2012
by
Christoph Mallon
Browse files
bechordal: Remove the write-only attribute pressure from struct border_t.
parent
6ee1fce9
Changes
2
Hide whitespace changes
Inline
Side-by-side
ir/be/bechordal_common.c
View file @
ecfcdc3a
...
...
@@ -36,9 +36,7 @@ DEBUG_ONLY(static firm_dbg_module_t *dbg = NULL;)
/* Make a fourcc for border checking. */
#define BORDER_FOURCC FOURCC('B', 'O', 'R', 'D')
static
inline
border_t
*
border_add
(
be_chordal_env_t
*
env
,
struct
list_head
*
head
,
ir_node
*
irn
,
unsigned
step
,
unsigned
pressure
,
unsigned
is_def
,
unsigned
is_real
)
static
inline
border_t
*
border_add
(
be_chordal_env_t
*
const
env
,
struct
list_head
*
const
head
,
ir_node
*
const
irn
,
unsigned
const
step
,
unsigned
const
is_def
,
unsigned
const
is_real
)
{
border_t
*
b
;
...
...
@@ -72,7 +70,6 @@ static inline border_t *border_add(be_chordal_env_t *env, struct list_head *head
DEBUG_ONLY
(
assert
(
b
&&
b
->
magic
==
BORDER_FOURCC
&&
"Illegal border encountered"
);)
}
b
->
pressure
=
pressure
;
b
->
is_def
=
is_def
;
b
->
is_real
=
is_real
;
b
->
irn
=
irn
;
...
...
@@ -88,16 +85,15 @@ void create_borders(ir_node *block, void *env_ptr)
{
/* Convenience macro for a def */
#define border_def(irn, step, real) \
border_add(env, head, irn, step,
pressure--,
1, real)
border_add(env, head, irn, step, 1, real)
/* Convenience macro for a use */
#define border_use(irn, step, real) \
border_add(env, head, irn, step,
++pressure,
0, real)
border_add(env, head, irn, step, 0, real)
be_chordal_env_t
*
const
env
=
(
be_chordal_env_t
*
)
env_ptr
;
unsigned
step
=
0
;
unsigned
pressure
=
0
;
struct
list_head
*
head
;
/* Set up the border list in the block info */
...
...
@@ -130,7 +126,7 @@ void create_borders(ir_node *block, void *env_ptr)
if
(
is_Phi
(
irn
))
break
;
DB
((
dbg
,
LEVEL_1
,
"
\t
insn: %+F
, pressure: %d
\n
"
,
irn
,
pressure
));
DB
((
dbg
,
LEVEL_1
,
"
\t
insn: %+F
\n
"
,
irn
));
be_foreach_definition
(
irn
,
env
->
cls
,
def
,
req
,
/*
...
...
ir/be/bechordal_t.h
View file @
ecfcdc3a
...
...
@@ -31,7 +31,6 @@ struct border_t {
border_t
*
other_end
;
/**< The other end of the border. */
ir_node
*
irn
;
/**< The node. */
unsigned
step
;
/**< The number equal to the interval border. */
unsigned
pressure
;
/**< The pressure at this interval border. (The border itself is counting). */
unsigned
is_def
:
1
;
/**< Does this border denote a use or a def. */
unsigned
is_real
:
1
;
/**< Is the def/use real? Or is it just
inserted at block beginnings or ends
...
...
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