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
e9788b11
Commit
e9788b11
authored
Feb 20, 2010
by
Christoph Mallon
Browse files
Prefer get_mode_null() over get_tarval_null().
[r27189]
parent
a361d426
Changes
6
Show whitespace changes
Inline
Side-by-side
include/libfirm/old_fctnames.h
View file @
e9788b11
...
...
@@ -142,8 +142,8 @@ typedef ir_type type;
#define tarval_get_mode_output_option(X) get_tarval_mode_output_option(X)
#define tarval_bitpattern(X) get_tarval_bitpattern(X)
#define tarval_sub_bits(X, Y) get_tarval_sub_bits(X, Y)
#define get_tarval_P_void() get_
tarval
_null(mode_P)
#define tarval_P_void get_
tarval
_null(mode_P)
#define get_tarval_P_void() get_
mode
_null(mode_P)
#define tarval_P_void get_
mode
_null(mode_P)
#define tarval_is_entity(X) 0
#define get_tarval_entity(X) ((ir_entity *)NULL)
...
...
ir/ana/irmemory.c
View file @
e9788b11
...
...
@@ -188,7 +188,7 @@ static ir_alias_relation different_index(const ir_node *idx1, const ir_node *idx
}
/* m1 is now the signed one */
if
(
tarval_cmp
(
tv1
,
get_
tarval
_null
(
m1
))
&
(
pn_Cmp_Eq
|
pn_Cmp_Gt
))
{
if
(
tarval_cmp
(
tv1
,
get_
mode
_null
(
m1
))
&
(
pn_Cmp_Eq
|
pn_Cmp_Gt
))
{
/* tv1 is signed, but >= 0, simply cast into unsigned */
tv1
=
tarval_convert_to
(
tv1
,
m2
);
}
else
{
...
...
ir/be/arm/arm_transform.c
View file @
e9788b11
...
...
@@ -1049,7 +1049,7 @@ static int is_fpa_immediate(tarval *tv)
i = 2;
}
if (tarval_cmp(tv, get_
tarval
_null(mode)) & pn_Cmp_Lt) {
if (tarval_cmp(tv, get_
mode
_null(mode)) & pn_Cmp_Lt) {
tv = tarval_neg(tv);
res = -1;
}
...
...
@@ -1609,7 +1609,7 @@ static void arm_pretransform_node(void)
static
void
arm_init_fpa_immediate
(
void
)
{
/* 0, 1, 2, 3, 4, 5, 10, or 0.5. */
fpa_imm
[
0
][
fpa_null
]
=
get_
tarval
_null
(
mode_F
);
fpa_imm
[
0
][
fpa_null
]
=
get_
mode
_null
(
mode_F
);
fpa_imm
[
0
][
fpa_one
]
=
get_mode_one
(
mode_F
);
fpa_imm
[
0
][
fpa_two
]
=
new_tarval_from_str
(
"2"
,
1
,
mode_F
);
fpa_imm
[
0
][
fpa_three
]
=
new_tarval_from_str
(
"3"
,
1
,
mode_F
);
...
...
@@ -1618,7 +1618,7 @@ static void arm_init_fpa_immediate(void)
fpa_imm
[
0
][
fpa_ten
]
=
new_tarval_from_str
(
"10"
,
2
,
mode_F
);
fpa_imm
[
0
][
fpa_half
]
=
new_tarval_from_str
(
"0.5"
,
3
,
mode_F
);
fpa_imm
[
1
][
fpa_null
]
=
get_
tarval
_null
(
mode_D
);
fpa_imm
[
1
][
fpa_null
]
=
get_
mode
_null
(
mode_D
);
fpa_imm
[
1
][
fpa_one
]
=
get_mode_one
(
mode_D
);
fpa_imm
[
1
][
fpa_two
]
=
new_tarval_from_str
(
"2"
,
1
,
mode_D
);
fpa_imm
[
1
][
fpa_three
]
=
new_tarval_from_str
(
"3"
,
1
,
mode_D
);
...
...
@@ -1627,7 +1627,7 @@ static void arm_init_fpa_immediate(void)
fpa_imm
[
1
][
fpa_ten
]
=
new_tarval_from_str
(
"10"
,
2
,
mode_D
);
fpa_imm
[
1
][
fpa_half
]
=
new_tarval_from_str
(
"0.5"
,
3
,
mode_D
);
fpa_imm
[
2
][
fpa_null
]
=
get_
tarval
_null
(
mode_E
);
fpa_imm
[
2
][
fpa_null
]
=
get_
mode
_null
(
mode_E
);
fpa_imm
[
2
][
fpa_one
]
=
get_mode_one
(
mode_E
);
fpa_imm
[
2
][
fpa_two
]
=
new_tarval_from_str
(
"2"
,
1
,
mode_E
);
fpa_imm
[
2
][
fpa_three
]
=
new_tarval_from_str
(
"3"
,
1
,
mode_E
);
...
...
ir/be/ia32/ia32_transform.c
View file @
e9788b11
...
...
@@ -526,7 +526,7 @@ ir_entity *ia32_gen_fp_known_const(ia32_known_const_t kct)
ir_initializer_t
*
initializer
=
create_initializer_compound
(
2
);
set_initializer_compound_value
(
initializer
,
0
,
create_initializer_tarval
(
get_
tarval
_null
(
mode
)));
create_initializer_tarval
(
get_
mode
_null
(
mode
)));
set_initializer_compound_value
(
initializer
,
1
,
create_initializer_tarval
(
tv
));
...
...
ir/ir/irprofile.c
View file @
e9788b11
...
...
@@ -423,7 +423,7 @@ ir_graph *ir_profile_instrument(const char *filename, unsigned flags)
/* initialize count array */
NEW_ARR_A
(
tarval
*
,
tarval_array
,
n_blocks
);
tv
=
get_
tarval
_null
(
mode_Iu
);
tv
=
get_
mode
_null
(
mode_Iu
);
for
(
i
=
0
;
i
<
n_blocks
;
++
i
)
{
tarval_array
[
i
]
=
tv
;
}
...
...
ir/lower/lower_mode_b.c
View file @
e9788b11
...
...
@@ -120,7 +120,7 @@ static ir_node *create_set(ir_node *node)
tarval
*
tv_one
=
get_mode_one
(
mode
);
ir_node
*
one
=
new_d_Const
(
dbgi
,
tv_one
);
ir_node
*
block
=
get_nodes_block
(
node
);
tarval
*
tv_zero
=
get_
tarval
_null
(
mode
);
tarval
*
tv_zero
=
get_
mode
_null
(
mode
);
ir_node
*
zero
=
new_d_Const
(
dbgi
,
tv_zero
);
ir_node
*
set
=
new_rd_Mux
(
dbgi
,
block
,
node
,
zero
,
one
,
mode
);
...
...
@@ -241,7 +241,7 @@ static ir_node *lower_node(ir_node *node)
case
iro_Conv
:
{
ir_node
*
pred
=
get_Conv_op
(
node
);
ir_mode
*
mode
=
get_irn_mode
(
pred
);
tarval
*
tv_zeroc
=
get_
tarval
_null
(
mode
);
tarval
*
tv_zeroc
=
get_
mode
_null
(
mode
);
ir_node
*
zero_cmp
=
new_d_Const
(
dbgi
,
tv_zeroc
);
ir_node
*
cmp
=
new_rd_Cmp
(
dbgi
,
block
,
pred
,
zero_cmp
);
...
...
@@ -335,7 +335,7 @@ synth_zero_one:
tarval
*
tv_one
=
get_mode_one
(
mode
);
res
=
new_d_Const
(
dbgi
,
tv_one
);
}
else
if
(
tv
==
get_tarval_b_false
())
{
tarval
*
tv_zero
=
get_
tarval
_null
(
mode
);
tarval
*
tv_zero
=
get_
mode
_null
(
mode
);
res
=
new_d_Const
(
dbgi
,
tv_zero
);
}
else
{
panic
(
"invalid boolean const %+F"
,
node
);
...
...
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