diff options
author | Richard Kenner <kenner@gcc.gnu.org> | 1993-11-19 18:36:25 -0500 |
---|---|---|
committer | Richard Kenner <kenner@gcc.gnu.org> | 1993-11-19 18:36:25 -0500 |
commit | 9061e4cdc9c63ff6f57f60bf8df585c14526bb89 (patch) | |
tree | 12e6662fd709dfd201c1ddcd3e68be653568502b /gcc/optabs.c | |
parent | 2dd484ed8ede94cd8940bbdfd8fa3d41c812430c (diff) | |
download | gcc-9061e4cdc9c63ff6f57f60bf8df585c14526bb89.tar.gz |
(expand_complex_abs): Replace some erroneous uses of MODE with
SUBMODE.
From-SVN: r6118
Diffstat (limited to 'gcc/optabs.c')
-rw-r--r-- | gcc/optabs.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/gcc/optabs.c b/gcc/optabs.c index de0098bdefb..6a5a5843983 100644 --- a/gcc/optabs.c +++ b/gcc/optabs.c @@ -2030,12 +2030,15 @@ expand_complex_abs (mode, op0, target, unsignedp) real = gen_realpart (submode, op0); imag = gen_imagpart (submode, op0); + /* Square both parts. */ - real = expand_mult (mode, real, real, NULL_RTX, 0); - imag = expand_mult (mode, imag, imag, NULL_RTX, 0); + real = expand_mult (submode, real, real, NULL_RTX, 0); + imag = expand_mult (submode, imag, imag, NULL_RTX, 0); + /* Sum the parts. */ total = expand_binop (submode, add_optab, real, imag, 0, 0, OPTAB_LIB_WIDEN); + /* Get sqrt in TARGET. Set TARGET to where the result is. */ target = expand_unop (submode, sqrt_optab, total, target, 0); if (target == 0) |