re PR tree-optimization/37879 (ICE with "wrong" use of noreturn attribute and optimiz...
authorJakub Jelinek <jakub@redhat.com>
Mon, 27 Oct 2008 20:36:32 +0000 (21:36 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Mon, 27 Oct 2008 20:36:32 +0000 (21:36 +0100)
commit6a16e934557199b55b389fd86241297099a0a7ec
treeebeb7fd560865467cdcbc8475c88d93d3693497a
parent8f0f2a1dfd96bc496c50a264d2482daa254490aa
re PR tree-optimization/37879 (ICE with "wrong" use of noreturn attribute and optimization)

PR tree-optimization/37879
* predict.c (tree_estimate_probability): Check if last_stmt is
non-NULL before dereferencing it.

* gcc.dg/pr37879.c: New test.

From-SVN: r141390
gcc/ChangeLog
gcc/predict.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/pr37879.c [new file with mode: 0644]