On Tue, 15 Feb 2005, Daniel Berlin wrote: > On Tue, 2005-02-15 at 11:31 +0100, Richard Guenther wrote: > > > Wether fully_constant_expression > > is in error, or the assert, I do not know. But I guess other > > kind of folding could trigger this, too. > > Neither is really in error, it should catch exactly this case :). > This is a real bug, but in get_value_handle. > > Fully_constant_expression only returns something other than what you > passed it when it folded to something to an is_gimple_min_invariant. > get_value_handle MUST return the expression when handed an > is_gimple_min_invariant thing. > > And we have a winner! > get_value_handle is returning NULL instead of expr when handed your > expression. > > Move the is_gimple_min_invariant check in get_value_handle above the > other checks, and your bug should be fixed. > > I'll add a comment stating that get_value_handle is *required* to return > the expression when it is is_gimple_min_invariant when I do that. > > Please try the attached
Indeed, the patch fixes the problem and I'm happy again ;) Thanks for the quick fix, Richard. -- Richard Guenther <richard dot guenther at uni-tuebingen dot de> WWW: http://www.tat.physik.uni-tuebingen.de/~rguenth/