From: Rajiv Ellepola Subject: Problem with double on large program To: djgpp AT sun DOT soe DOT clarkson DOT edu Date: Sat, 12 Aug 1995 00:14:22 +0800 (WST) Hello All, I got a strange problem in that when I run a small program which does the following : int u1 = 350, u2 = 207, v1 = 296, v2 = 408; printf("%lf\n", atan2((double)(u1-u2), (double)(v1-v2))); it works fine, but when I try to do the same thing in a very large program, the program crashes giving the following dump. Floating point exception at eip=26b79 eax=00000122 ebx=7ffffc0f ecx=00000000 edx=00000000 esi=7fffe891 edi=0000000e ebp=7fffe824 esp=7fffe7bc cs=d8 ds=48 es=48 fs=48 gs=38 ss=48 cr2=00003076 Call frame traceback EIPs: 0x00026b79 0x000265a6 0x00024b28 0x00023ae5 0x00022218 Would it be possible for some one to tell me what the problem is ? ( I am using a 486PC. The code runs fine under unix ). \\__/(\ Thank you very much, Q Q \) Rajiv =(_T_)= -------------------------------------------------------------------------- Rajiv Ellepola, Robotics & Vision Research Group, _--_|\ Internet: rajiv AT cs DOT uwa DOT edu DOT au Department of Computer Science, / \ Tel (work): +61 9 380 3778 The University of Western Australia,*_.--._/ Fax (work): +61 9 380 1089 Western Australia 6907. v -------------------------------------------------------------------------- Humble experiments in early vertebrates eventually resulted in human beings. - Hans Moravec Diplomacy is the ability to tell someone to "Go to hell" in such a way that he looks forward to the trip.