Sun Studio 12 Update 1: Debugging a Program With dbx

Showing Interval Expressions

To show an interval expression in dbx, type:


demo% cat ShowInterval.f95
   INTERVAL v
   v = [ 37.1, 38.6 ]
   END
demo% f95 -g -xia ShowInterval.f95
demo% dbx a.out
(dbx) stop in MAIN
(2) stop in MAIN
(dbx) run
Running: a.out
(process id 5217)
stopped in MAIN at line 2 in file "ShowInterval.f95"
    2      v = [ 37.1, 38.6 ]
(dbx) whatis v
INTERVAL*16  v
(dbx) print v
v = [0.0,0.0]
(dbx) next
stopped in MAIN at line 3 in file "ShowInterval.f95"
    3      END
(dbx) print v
v = [37.1,38.6]
(dbx) print v+[0.99,1.01]
v+[0.99,1.01] = [38.09,39.61]
(dbx) quit
demo%

Note –

Interval expressions are supported only for programs compiled to run on SPARC based platforms, with -xarch={sse|sse2} to run on Solaris x86 SSE/SSE2 Pentium 4-compatible platforms, or with -xarch=amd64 to run on x64 platforms.