From owner-freebsd-questions Mon Feb 2 19:24:57 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id TAA13172 for questions-outgoing; Mon, 2 Feb 1998 19:24:57 -0800 (PST) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from ix.netcom.com (sil-wa4-29.ix.netcom.com [207.93.136.93]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id TAA13080 for ; Mon, 2 Feb 1998 19:24:40 -0800 (PST) (envelope-from tomdean@ix.netcom.com) Received: (from tomdean@localhost) by ix.netcom.com (8.8.8/8.8.8) id TAA20244; Mon, 2 Feb 1998 19:24:06 -0800 (PST) (envelope-from tomdean) Date: Mon, 2 Feb 1998 19:24:06 -0800 (PST) Message-Id: <199802030324.TAA20244@ix.netcom.com> From: Thomas Dean To: bartol@salk.edu CC: freebsd-questions@FreeBSD.ORG, mika@sdna2.ucsd.edu In-reply-to: (message from Tom Bartol on Mon, 2 Feb 1998 16:33:30 -0800 (PST)) Subject: Re: IEEE Floating Point question: Inf and NaN Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG X-To-Unsubscribe: mail to majordomo@FreeBSD.org "unsubscribe questions" What are you using to compile your code? What version of FreeBSD are you running? What is your cpu? I tried: #include #include main() { double x, y, z; x = 1.0; y = 0.0; z = x/y; printf("1/0 z = %f\n",z); x = 0.0; y = 0.0; z = x/y; printf("0/0 z = %f\n",z); } cc -O2 -m486 -pipe xx.c -o xx xx 1/0 z = Inf 0/0 z = NaN cc -v gcc version 2.7.2.1 uname -a FreeBSD celebris 3.0-CURRENT FreeBSD 3.0-CURRENT #0: \ Sun Feb 1 19:58:49 PST 1998 \ root@celebris:/usr/src/sys/compile/CELEBRIS-SMP i386