This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/38564] [4.4 Regression] ICE in insert_into_preds_of_block
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Dec 2008 02:09:05 -0000
- Subject: [Bug tree-optimization/38564] [4.4 Regression] ICE in insert_into_preds_of_block
- References: <bug-38564-7151@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from pinskia at gcc dot gnu dot org 2008-12-18 02:09 -------
Reduced testcase:
struct list_head {
struct list_head *next, *prev;
};
struct list_head *__current_thread_info;
void test_ti_thread_flag(void*);
int __do_page_cache_readahead( int nr_to_read )
{
struct list_head page_pool = { &(page_pool), &(page_pool) };
int page_idx;
for (page_idx = 0; page_idx < nr_to_read; page_idx++)
test_ti_thread_flag(__current_thread_info);
return (page_pool.next == &page_pool);
}
--- CUT ---
I think this comes from PREing of comparisons.
Changing this to just return of page_pool.next works. now I want to say this
code should always return true as page_pool does not escape at all but I don't
think GCC's aliasing is smart enough anyways.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
GCC build triplet|x86_64-unknown-linux-gnu |
GCC host triplet|x86_64-unknown-linux-gnu |
GCC target triplet|x86_64-unknown-linux-gnu |
Last reconfirmed|0000-00-00 00:00:00 |2008-12-18 02:09:04
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38564