This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/67306] New: Patterns ICEs when moved using "simplify and match"


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

            Bug ID: 67306
           Summary: Patterns ICEs when moved using "simplify and match"
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: hs.naveen2u at gmail dot com
  Target Milestone: ---

Created attachment 36232
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=36232&action=edit
Testcase to reproduce the issue

Hi,

I am trying to move some patterns using simplify and match.
Moved some patterns and observed that some patterns ICEs for
Long Double and Float patterns.

The patterns which does the operations are:-
========================================================
 /* Simplify sqrt(x) * sqrt(y) -> sqrt(x*y).  */
(for root (SQRT CBRT)
 (simplify
  (mult (root:s @0) (root:s @1))
  (root (mult @0 @1))))

 /* Simplify pow(x,y) * pow(x,z) -> pow(x,y+z). */
 (simplify
  (mult (POW:s @0 @1) (POW:s @0 @2))
    (POW @0 (plus @1 @2)))

 /* Simplify expN(x) * expN(y) -> expN(x+y). */
(for expss (EXP EXP2 EXP10 POW10)
 (simplify
  (mult (exps:s @0) (exps:s @1))
   (exps (plus @0 @1))))

/* Simplify x / expN(y) into x*expN(-y). */
(for expss (EXP EXP2 EXP10 POW10)
 (simplify
  (rdiv @0 (exps:s @1))
   (mult @0 (exps (negate @1)))))
========================================================

All the operations in the attached testcase results in SEG FAULT:-
aarch64-thunder-elf-gcc simlify-2.c -O2 -funsafe-math-optimizations -lm


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]