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
a81596fb
Commit
a81596fb
authored
Nov 10, 2011
by
yb9976
Browse files
Prevent computations with tarval_bad.
This fixes opt/fehler206.c.
parent
133cd801
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/opt/opt_osr.c
View file @
a81596fb
...
...
@@ -1156,6 +1156,12 @@ static ir_node *applyOneEdge(ir_node *iv, ir_node *rc, LFTR_edge *e, iv_env *env
panic
(
"Unsupported opcode"
);
}
if
(
tv
==
tarval_bad
||
tv_init
==
tarval_bad
)
{
tarval_set_integer_overflow_mode
(
ovmode
);
DB
((
dbg
,
LEVEL_4
,
" = OVERFLOW"
));
return
NULL
;
}
if
(
pscc
->
code
==
iro_Add
)
{
tv_end
=
tarval_add
(
tv
,
tv_incr
);
}
else
{
...
...
@@ -1165,7 +1171,7 @@ static ir_node *applyOneEdge(ir_node *iv, ir_node *rc, LFTR_edge *e, iv_env *env
tarval_set_integer_overflow_mode
(
ovmode
);
if
(
tv
==
tarval_bad
||
tv_init
==
tarval_bad
||
tv
_end
==
tarval_bad
)
{
if
(
tv_end
==
tarval_bad
)
{
DB
((
dbg
,
LEVEL_4
,
" = OVERFLOW"
));
return
NULL
;
}
...
...
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