]> gcc.gnu.org Git - gcc.git/commit
tree-optimization/105431 - another overflow in powi handling
authorRichard Biener <rguenther@suse.de>
Fri, 29 Apr 2022 06:45:48 +0000 (08:45 +0200)
committerRichard Biener <rguenther@suse.de>
Fri, 27 May 2022 13:14:27 +0000 (15:14 +0200)
commite41fa23451c965516a37282268231933fd948845
treecada5bbe7d26a14734896a3047d718637e80c75b
parentebe6ffee1aa2d819e4fbdf4130e054a33c274b38
tree-optimization/105431 - another overflow in powi handling

This avoids undefined signed overflow when calling powi_as_mults_1.

2022-04-29  Richard Biener  <rguenther@suse.de>

PR tree-optimization/105431
* tree-ssa-math-opts.c (powi_as_mults_1): Make n unsigned.
(powi_as_mults): Use absu_hwi.
(gimple_expand_builtin_powi): Remove now pointless n != -n
check.

(cherry picked from commit 44b09adb9bad99dd7e3017c5ecefed7f7c9a1590)
gcc/tree-ssa-math-opts.c
This page took 0.062627 seconds and 6 git commands to generate.