Floating-point underflow on IBM3090

Floating-point underflow on IBM3090

Post by Tsung-lung » Sat, 05 Sep 1992 10:44:04



Dear Netters,

Here is a question about the VS fortran on IBM3090 running AIX/370.

I compiled and ran the following test program.

        program   tt
        double precision  x, y
        x = 1.0d-40
        y = x * x
        write(6,*) x, y
        stop
        end

The compilation command I used was "fvs -f'optimize(3)' -o tt tt.f".
The followings are what the computer responds.

0AFB208I VFNTH : PROGRAM INTERRUPT - FLOATING-POINT UNDERFLOW EXCEPTION
         VFNTH : PSW 07ED1200001001A2, REGISTER CONTAINS 7E4BE2B05D35848D0000000
000000000
         VFNTH : LAST EXECUTED FORTRAN STATEMENT IN PROGRAM TT (OFFSET 00000072)
.
0TRACEBACK OF CALLING ROUTINES; MODULE ENTRY ADDRESS = 00100130.
 -----------------------------------------------------------------------------
  TT (00100130) CALLED BY OPERATING SYSTEM.
 -----------------------------------------------------------------------------
0STANDARD CORRECTIVE ACTION TAKEN. EXECUTION CONTINUING.
  0.100000000000000001E-39  0.000000000000000000E+00
0 MESSAGE SUMMARY: MESSAGE NUMBER - COUNT          

I learned from page 404 of "VS FORTRAN Version 2 Language and Library Reference
Release 5(SC26-4221-7)" that the message appears because (1.0d-40)**2 is
less than
the underflow limit(5.4d-79).  I wonder if there is any way to get rid of the
message given by he computer.

When underflow arithmatics occures, isn't it true that the number is simply
taken as zero?  Why does the IBM machine complains about this?

Any comments on this issue will be appreciated.  Please e-mail me at

Sincerely,

Tsung

PS.  The above question of mine was initiated by a subroutine in LAPACK
I am trying to call.  The subroutine is DLAMCH and is not included in this
message.  

The following is my test program.

      program dlamchtest
      external  dlamch
      print *, 'e', dlamch('e')
      print *, 's', dlamch('s')
      print *, 'b', dlamch('b')
      print *, 'p', dlamch('p')
      print *, 'n', dlamch('n')
      print *, 'r', dlamch('r')
      print *, 'm', dlamch('m')
      print *, 'u', dlamch('u')
      print *, 'l', dlamch('l')
      print *, 'o', dlamch('o')
      stop
      end

After giving me the following message a few times, the computer evetually
get the results right.

The message given by the IBM3090:

AFB208I VFNTH : PROGRAM INTERRUPT - FLOATING-POINT UNDERFLOW EXCEPTION
         VFNTH : PSW 07ED1200001015D0, REGISTER CONTAINS 7F100000000000000000000
000000000
         VFNTH : LAST EXECUTED FORTRAN STATEMENT IN PROGRAM DLAMC4 (OFFSET 00000
128).
0TRACEBACK OF CALLING ROUTINES; MODULE ENTRY ADDRESS = 00100138.
 -----------------------------------------------------------------------------
  DLAMC4 (001014A8) CALLED BY DLAMC2 (00100D90) AT OFFSET 00000286.
   ARGUMENT LIST AT 007FF818.
     ARG. NO.   ADDRESS          INTEGER        REAL        CHAR   HEXADECIMAL
           1   007FF8B8 :            -64   -0.723698E+76   '....'   FFFFFFC0
           2   007FF888 :     1091567616    0.100000E+01   'A...'   41100000
           3   00200ACC :             16    0.000008E-78   '....'   00000010
 -----------------------------------------------------------------------------
  DLAMC2 (00100D90) CALLED BY DLAMCH (00100538) AT OFFSET 00000098.
   ARGUMENT LIST AT 007FF9F8.
     ARG. NO.   ADDRESS          INTEGER        REAL        CHAR   HEXADECIMAL
           1   007FFA4C :        1136156    0.584843E-78   '..V.'   0011561C
           2   007FFA40 :        1116516    0.574733E-78   '...d'   00110964
           3   007FFA50 :        1127532    0.580404E-78   '..4l'   0011346C
           4   00200848 :              0    0.000000E+00   '....'   00000000
           5   007FFA44 :        8387080    0.431730E-77   '....'   007FFA08
           6   00200830 :              0    0.000000E+00   '....'   00000000

           8   00200838 :              0    0.000000E+00   '....'   00000000
 -----------------------------------------------------------------------------
  DLAMCH (00100538) CALLED BY DLAMEST (00100138) AT OFFSET 0000008E.
   ARGUMENT LIST AT 007FFB78.
     ARG. NO.   ADDRESS          INTEGER        REAL        CHAR   HEXADECIMAL
           1   00200751 :     1702887424    0.178406E+45   'e...'   65800000
 -----------------------------------------------------------------------------
  DLAMEST (00100138) CALLED BY OPERATING SYSTEM.
 -----------------------------------------------------------------------------
0STANDARD CORRECTIVE ACTION TAKEN. EXECUTION CONTINUING.

The results given by the computer is

 s 0.138178697E-75
 b  16.0000000    
 p 0.355271368E-14
 n  14.0000000    
 r 0.000000000E+00
 m -64.0000000    
 u 0.539760535E-78
 l  63.0000000    
 o 0.723700515E+76

Any idea to fix this?

 
 
 

Floating-point underflow on IBM3090

Post by G. Vitilla » Sun, 06 Sep 1992 03:45:07



>I compiled and ran the following test program.
>        program   tt
>        double precision  x, y
>        x = 1.0d-40
>        y = x * x
>        write(6,*) x, y
>        stop
>        end
>The compilation command I used was "fvs -f'optimize(3)' -o tt tt.f".
>The followings are what the computer responds.
>0AFB208I VFNTH : PROGRAM INTERRUPT - FLOATING-POINT UNDERFLOW EXCEPTION
>         VFNTH : PSW 07ED1200001001A2, REGISTER CONTAINS 7E4BE2B05D35848D0000000
>000000000
>         VFNTH : LAST EXECUTED FORTRAN STATEMENT IN PROGRAM TT (OFFSET 00000072)
>.
>0TRACEBACK OF CALLING ROUTINES; MODULE ENTRY ADDRESS = 00100130.
> -----------------------------------------------------------------------------
>  TT (00100130) CALLED BY OPERATING SYSTEM.
> -----------------------------------------------------------------------------
>0STANDARD CORRECTIVE ACTION TAKEN. EXECUTION CONTINUING.
>  0.100000000000000001E-39  0.000000000000000000E+00
>0 MESSAGE SUMMARY: MESSAGE NUMBER - COUNT          

Did you try to run:

        tt -noxuflow,

I think that is what you need. Regards, G.Vitillaro
--

University of Perugia Italy         |  06100 Perugia  Phone:+39.75.585-2200
---------------------------------------------------------------------------
All comments/opinions are mine and don't represent those of IBM

 
 
 

1. How to catch Floating point overflow/underflow

Hello netters,

I have a very numerically intensive calculation program under hand. It
sometimes happen that I got NaN values into some of my calculations. Is
there anyway to catch the statements that lead to such floating point
errors (I don't divide by zero any where)? I am using g++/gdb
environment. Thanks you for your help.

Khaled
--

Department of Computer Science     |     Voice : 919-515-7533 (Office)
North Carolina State University    |             919-515-7346 (CCSP Lab)
Raleigh, NC 27695-8207, U.S.A.     |     To be is to do!

2. Enlightenment Question

3. floating-point arithmatic in ksh (or any other shell)

4. Why a segmentation error?

5. Question on floating-point numbers

6. what does "ENTRY, .globl, .org, .fill" mean in "head.S"

7. floating-point arithmetic in bash? [Q]

8. RH4.2newbie question

9. Floating-point discrepency under debian linux

10. How to catch floating-point exception?

11. Floating-Point operation fails on PowerPC 860

12. floating-point & bechmarks

13. ANSI/IEEE double-precision floating-point arithmetic?