From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id F1FCB386182B; Sat, 19 Nov 2022 00:25:29 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F1FCB386182B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1668817529; bh=TQzBHEfbdre+2J4toIYXRh5X3FDPQeyauoqp9iBAS3g=; h=From:To:Subject:Date:In-Reply-To:References:From; b=kE9WutVcFQEnCREK69dtAi8byWkm/1T5kgnL7lvpX0ulqGIyUcYP+HHu8XBXQnXW3 UEVGoaUnwliw6DwhkMQ4M9O/iEGxVhe9RTbEn7MG4WNQl+xNdPVcpLZbp+qH/DtHZ5 r/ICbT7YAx4LSl+gmieuIYcXoB+3yjNbNo1w1kGk= From: "sgk at troutmask dot apl.washington.edu" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/107753] gfortran returns NaN in complex divisions (x+x*I)/(x+x*I) and (x+x*I)/(x-x*I) Date: Sat, 19 Nov 2022 00:25:28 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 12.2.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: sgk at troutmask dot apl.washington.edu X-Bugzilla-Status: WAITING X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D107753 --- Comment #9 from Steve Kargl -= -- On Fri, Nov 18, 2022 at 11:24:29PM +0000, sgk at troutmask dot apl.washington.edu wrote: >=20 > Does anyone know what is meant by "Fortran rules"? F66 does not > have any particular algorithm specified. I'll look at F77 shortly. >=20 Well, I hunted down the origins of -fcx-fortran-rules. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D29549 So, it appears to be an optimization, where Smith's algorithm will fail for extreme values of the real and imaginary parts of the complex number.=