[Bug tree-optimization/126693] Fold abs (x) * abs (y) -> abs (x * y)

"dipesh.sharma at amd dot com via Gcc-bugs" <[email protected]>
Newsgroups gmane.comp.gcc.bugs
Message-ID <[email protected]/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126693

Dipesh Sharma <dipesh.sharma at amd dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dipesh.sharma at amd dot com

--- Comment #2 from Dipesh Sharma <dipesh.sharma at amd dot com> ---
I believe it is valid, GCC is generating two abs and mul.

I tested with -Ofast, -O3, -O0 and -frounding-math. Below is the generated
assembly.

"f":
        andpd   xmm0, XMMWORD PTR .LC0[rip]
        andpd   xmm1, XMMWORD PTR .LC0[rip]
        mulsd   xmm0, xmm1
        ret
.LC0:
        .long   -1
        .long   2147483647
        .long   0
        .long   0


Can I take this up ?
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.