https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86835

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Sat Aug 11 11:29:12 2018
New Revision: 263487

URL: https://gcc.gnu.org/viewcvs?rev=263487&root=gcc&view=rev
Log:
        PR tree-optimization/86835
        * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
        new_stmt after def_gsi, make sure to insert new_square_stmt after
        that stmt, not 2 stmts before it.

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

Added:
    trunk/gcc/testsuite/gcc.dg/pr86835.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree-ssa-math-opts.c

Reply via email to