This chapter contains sample programs that illustrate the symbol table
representations of various language constructs.
The examples are organized
by source language and each consists of a program listing and the partial
symbol table contents for that program.
The system symbol table dumpers
stdump(1)odump(1)17.1 C
17.1.1 Unnamed Structure
See
Section 11.3.3.3
for related information.
Source Listing
struct S1 {
int abc;
struct {int x; signed int y; unsigned int z;};
int rst;
} s1;
Symbol Table Contents
File 0 Local Symbols: 0. (0)( 0) unname.c File Text symref 12 1. (1)( 0xc) Block Info symref 6 2. (2)( 0) x Member Info [ 3] int 3. (2)(0x20) y Member Info [ 3] int 4. (2)(0x40) z Member Info [ 4] unsigned int 5. (1)( 0) End Info symref 1 6. (1)(0x14) S1 Block Info symref 11 7. (2)( 0) abc Member Info [ 3] int 8. (2)(0x20) Member Info [ 5] struct(file 0,index 1) 9. (2)(0x80) rst Member Info [ 3] int 10. (1)( 0) S1 End Info symref 6 11. (0)( 0) unname.c End Text symref 0 Externals Table: 0. (file 0)(0x14) s1 Global Common [7] struct(file 0,index 6)
17.2 C++
17.2.1 Base and Derived Classes
See
Section 11.3.3.6
for related information.
Source Listing
#include <iostream.h>
class employee {
char *name;
short age;
short deparment;
int salary;
public:
static int stest;
employee *next;
void print() const;
};
class manager : public employee {
employee emp;
employee *group;
short level;
public:
void print() const;
};
void employee::print() const
{
cout << "name is " << name << '\n';
}
void manager::print() const
{
employee::print();
}
void f()
{
manager m1,m2;
employee e1, e2;
employee *elist;
elist=&m1;
m1.next=&e1;
e1.next=&m2;
m2.next=&e2;
e2.next=0;
}
Symbol Table Contents
File 0 Local Symbols:
0. ( 0)( 0) bs6.cxx File Text symref 51
1. ( 1)( 0) manager Tag Info [ 4] class(file 0,index 2)
2. ( 1)(0x40) manager Block Info symref 11
3. ( 2)(0xc0) emp Member Info [ 6] class(file 0,index 12)
4. ( 2)(0x180) group Member Info [ 8] class*(file 0,index 12)
5. ( 2)(0x1c0) level Member Info [10] short
6. ( 2)( 0) manager::print(void) const
Proc Info [11] endref 9, void
7. ( 3)( 0) this Param Info [13] class Const *(file 0,
index 2)
8. ( 2)( 0) manager::print(void) const
End Info symref 6
9. ( 2)( 0) employee Base Class Info [ 6] class(file 0,index 12)
10. ( 1)( 0) manager End Info symref 2
11. ( 1)( 0) employee Tag Info [ 6] class(file 0,index 12)
12. ( 1)(0x18) employee Block Info symref 23
13. ( 2)( 0) name Member Info [15] char*
14. ( 2)(0x40) age Member Info [10] short
15. ( 2)(0x50) department Member Info [10] short
16. ( 2)(0x60) salary Member Info [ 3] int
17. ( 2)( 0) employee::stest
Static Info [ 3] int
18. ( 2)(0x80) next Member Info [ 8] class*(file 0,index 12)
19. ( 2)( 0) employee::print(void) const
Proc Info [16] endref 22, void
20. ( 3)( 0) this Param Info [18] class Const *(file 0,
index 12)
21. ( 2)( 0) employee::print(void) const
End Info symref 19
22. ( 1)( 0) employee End Info symref 12
23. ( 1)(0x9c) f(void) Proc Text [39] endref 32, void
24. ( 2)( 0x4) Block Text symref 31
25. ( 3)( -64) m1 Local Abs [ 4] class(file 0,index 2)
26. ( 3)(-128) m2 Local Abs [ 4] class(file 0,index 2)
27. ( 3)(-152) e1 Local Abs [ 6] class(file 0,index 12)
28. ( 3)(-176) e2 Local Abs [ 6] class(file 0,index 12)
29. ( 3)( 0x1) elist Local Register [ 8] class*(file 0,index 12)
30. ( 2)(0x24) End Text symref 24
31. ( 1)(0x2c) f(void) End Text symref 23
32. ( 1)( 0) employee::print(void) const
Proc Text [41] endref 37, void
33. ( 2)(0x28) this Param Abs [21] class Const * Const
(file 0,index 12)
34. ( 2)(0x14) Block Text symref 36
35. ( 2)(0x6c) End Text symref 34
36. ( 1)(0x74) employee::print(void) const
End Text symref 32
37. ( 1)(0x74) manager::print(void) const
Proc Text [43] endref 42, void
38. ( 2)(0x28) this Param Abs [23] class Const * Const
(file 0,index 2)
39. ( 2)(0x14) Block Text symref 41
40. ( 2)(0x1c) End Text symref 39
41. ( 1)(0x28) manager::print(void) const
End Text symref 37
42. ( 0)( 0) bs6.cxx End Text symref 0
17.2.2 Virtual Function Tables and Interludes
Source Listing
class Base1 {
public:
virtual int virtual_mem_func() { return 1; }
};
class Base2 : virtual public Base1 {
public:
virtual int virtual_mem_func() { return 2; }
};
class Base3 : public Base2 {
public:
virtual int virtual_mem_func() { return 3; }
};
int foo(Base1 *b1) {
return b1->virtual_mem_func();
}
int main() {
Base1 *b1;
Base2 *b2;
Base3 *b3;
int i,j,k;
i = foo(b1);
j = foo(b2);
k = foo(b3);
return 0;
}
Symbol Table Contents
File 0 Local Symbols:
0. ( 0)( 0) intrlde.cxx File Text symref 42
1. ( 1)( 0) Base1 Tag Info [ 4] class(file 0,index 2)
2. ( 1)( 0x8) Base1 Block Info symref 8
3. ( 2)( 0) __vptr Member Info [ 6] Virtual func table*
Array [(file 0, aux 3)0-0:64]
4. ( 2)( 0x1) Base1::virtual_mem_func(void)
Proc Info [11] endref 7, int
5. ( 3)( 0) this Param Info [13] class*(file 0,index 2)
6. ( 2)( 0) Base1::virtual_mem_func(void)
End Info symref 4
7. ( 1)( 0) Base1 End Info symref 2
8. ( 1)( 0) Base2 Tag Info [15] class(file 0,index 9)
9. ( 1)(0x18) Base2 Block Info symref 17
10. ( 2)( 0) __vptr Member Info [ 6] Virtual func table*
Array [(file 0, aux 3)0-0:64]
11. ( 2)(0x40) __bptr Member Info [ 6] Virtual func table*
Array [(file 0, aux 3)0-0:64]
12. ( 2)( 0x1) Base2::virtual_mem_func(void)
Proc Info [17] endref 15, int
13. ( 3)( 0) this Param Info [19] class*(file 0,index 9)
14. ( 2)( 0) Base2::virtual_mem_func(void)
End Info symref 12
15. ( 2)( 0) Base1 Virtual Base Class
Info [ 4] class(file 0,index 2)
16. ( 1)( 0) Base2 End Info symref 9
17. ( 1)( 0) Base3 Tag Info [21] class(file 0,index 18)
18. ( 1)(0x18) Base3 Block Info symref 26
19. ( 2)( 0) __vptr Member Info [ 6] Virtual func table*
Array [(file 0, aux 3)0-0:64]
20. ( 2)(0x40) __bptr Member Info [ 6] Virtual func table*
Array [(file 0, aux 3)0-0:64]
21. ( 2)( 0x1) Base3::virtual_mem_func(void)
Proc Info [23] endref 24, int
22. ( 3)( 0) this Param Info [25] class*(file 0,index 18)
23. ( 2)( 0) Base3::virtual_mem_func(void)
End Info symref 21
24. ( 2)( 0) Base2 Base Class Info [15] class(file 0,index 9)
25. ( 1)( 0) Base3 End Info symref 18
26. ( 1)( 0) foo(Base1*) Proc Text [27] endref 31, int
27. ( 2)(0x20) b1 Param Abs [13] class*(file 0,index 2)
28. ( 2)( 0xc) Block Text symref 30
29. ( 2)(0x30) End Text symref 28
30. ( 1)(0x3c) foo(Base1*) End Text symref 26
31. ( 1)(0x3c) main Proc Text [29] endref 41, int
32. ( 2)( 0x8) Block Text symref 40
33. ( 3)( -24) b1 Local Abs [13] class*(file 0,index 2)
34. ( 3)( -32) b2 Local Abs [19] class*(file 0,index 9)
35. ( 3)( -40) b3 Local Abs [25] class*(file 0,index 18)
36. ( 3)( -48) i Local Abs [ 3] int
37. ( 3)( -52) j Local Abs [ 3] int
38. ( 3)( -56) k Local Abs [ 3] int
39. ( 2)(0x80) End Text symref 32
40. ( 1)(0x8c) main End Text symref 31
41. ( 0)( 0) intrlde.cxx End Text symref 0
17.2.3 Namespace Definitions and Uses
See
Section 11.3.1.5
for related information.
Source Listing
ns1.h:
namespace ns1 {
class Cobj {};
extern int i1;
}
ns2.h:
namespace ns1 {
int x1(void);
}
ns.C:
#include "ns1.h"
#include "ns2.h"
namespace ns1 {
extern int part3;
}
int ns1::i1 = 1000;
int ns1::part3 = 3;
int ns1::x1(void) {
using namespace ns1;
return i1*10;
}
Symbol Table Contents
File 0 Local Symbols: 0. ( 0)( 0) ns.C File Text symref 7 1. ( 1)( 0) ns1::x1(void) Proc Text [4] endref 6, int 2. ( 2)( 0) Using Info [6] symref(file 1, index 1) 3. ( 2)( 0x8) Block Text symref 5 4. ( 2)(0x14) End Text symref 3 5. ( 1)(0x18) ns1::x1(void) End Text symref 1 6. ( 0)( 0) ns.C End Text symref 0 File 1 Local Symbols: 0. ( 0)( 0) ns1.h File Text symref 8 1. ( 1)( 0) ns1 Namespace Info symref 7 2. ( 2)( 0) ns1::x1(void) Proc Info [2] endref 4, int 3. ( 2)( 0) ns1::x1(void) End Info symref 2 4. ( 2)( 0) i1 Member Info [4] int 5. ( 2)( 0) part3 Member Info [4] int 6. ( 1)( 0) ns1 End Info symref 1 7. ( 0)( 0) ns1.h End Text symref 0 Externals Table: 0. (file 0)(0x50) ns1::i1 Global SData [3] int 1. (file 0)(0x58) ns1::part3 Global Sdata [3] int 2. (file 0)( 0) ns1::x1(void) Proc Text symref 1
See
Section 11.3.1.5.3
for related information.
Source Listing
uns.C:
namespace {
int usv1;
int usv2;
}
int privat(void) {
return usv1 + usv2;
}
Symbol Table Contents
File 0 Local Symbols: 0. ( 0)( 0) uns.C File Info symref 13 1. ( 1)( 0) Namespace Info symref 5 2. ( 2)( 0) <unnamed namespace>::usv1 Member Info [3] int 3. ( 2)( 0) <unnamed namespace>::usv2 Member Info [3] int 4. ( 1)( 0) End Info symref 1 5. ( 1)( 0) Using Info [4] symref(file 0, index 1) 6. ( 1)(0x50) <unnamed namespace>::usv1 Static SBss [3] int 7. ( 1)(0x54) <unnamed namespace>::usv2 Static SBss [3] int 8. ( 1)( 0) privat(void) Proc Text [5] endref 12, int 9. ( 2)( 0x8) Block Text symref 11 10. ( 2)(0x1c) End Text symref 9 11. ( 1)(0x20) End Text symref 8 12. ( 0)( 0) End Text symref 0
See
Section 11.3.1.5.2
for related information.
Source Listing
alias.C:
namespace long_namespace_name {
extern int nmem;
}
int get_nmem(void) {
namespace nknm = long_namespace_name;
namespace nknm2 = nknm;
return nknm::nmem;
}
Symbol Table Contents
File 0 Local Symbols 0. ( 0)( 0) alias.C File Text symref 11 1. ( 1)( 0) long_namespace_name Namespace Info symref 4 2. ( 2)( 0) nmem Member Info [3] int 3. ( 1)( 0) long_namespace_name End Info symref 1 4. ( 1)( 0) get_nmem(void) Proc Text [4] endref 10, int 5. ( 2)( 0x8) Block Text symref 9 6 ( 2)( 0) nknm Alias Info [5] symref(file 0,index 1) 7 ( 2)( 0) nknm2 Alias Info [6] symref(file 0,index 6) 8. ( 2)(0x10) End Text symref 5 9. ( 1)(0x14) get_nmem(void) End Text symref 4 10. ( 0)( 0) alias.C End Text symref 0 Externals Table 0. (file 0)(0x4) long_namespace_name::nmem Global Undefined [3]int 1. (file 0)( 0) get_nmem(void) Proc Text symref 4
See
Section 3.3.8
for related information.
Source Listing
#include <iostream.h>
class Vector {
int *p;
int sz;
public:
enum { max=1000 };
Vector(int);
class Range { };
class Size { };
int operator[](int i);
}; // Vector
Vector::Vector(int i) {
if (i>max) throw Size();
p=new int[i];
if (p) sz=i;
else sz=0;
}
int Vector::operator[](int i) {
if (0<=i && i<sz) return p[i];
throw Range();
}
void f() {
int i;
try {
cout<<"size?";
cin>>i;
Vector v(i);
cout<<v[i]<<"\n";
}
catch (Vector::Range) {
cout<< "bad news; outta here...\n";
}
catch (Vector::Size) {
cout<< "can't initialize to that size...\n";
}
} // f
main() {
f();
}
Symbol Table Contents
File 0 Local Symbols:
0. ( 0)( 0) exc.cxx File Text symref 59
1. ( 1)( 0) __throw_descriptor
Tag Info [ 4] struct(extended file -1,indexNil)
2. ( 1)( 0x5) Typdef Info [ 4] struct(extended file -1,indexNil)
3. ( 1)( 0) Vector Tag Info [16] class(file 0,index 4)
4. ( 1)(0x10) Vector Block Info symref 26
5. ( 2)( 0) p Member Info [18] int*
6. ( 2)(0x40) sz Member Info [ 3] int
7. ( 2)( 0) _DECCXX_generated_name_121c225d
Tag Info [19] enum(file 0,index 8)
8. ( 2)( 0x4) _DECCXX_generated_name_121c225d
Block Info symref 11
9. ( 3)(0x3e8) max Member Info [ 2] btNil
10. ( 2)( 0) _DECCXX_generated_name_121c225d
End Info symref 8
11. ( 2)( 0) Vector::Vector(int)
Proc Info [21] endref 15, class Reference
(file 0,index 4)
12. ( 3)( 0) this Param Info [24] class*(file 0,index 4)
13. ( 3)( 0) i Param Info [ 3] int
14. ( 2)( 0) Vector::Vector(int)
End Info symref 11
15. ( 2)( 0) Range Tag Info [26] class(file 0,index 16)
16. ( 2)( 0x1) Range Block Info symref 18
17. ( 2)( 0) Range End Info symref 16
18. ( 2)( 0) Size Tag Info [28] class(file 0,index 19)
19. ( 2)( 0x1) Size Block Info symref 21
20. ( 2)( 0) Size End Info symref 19
21. ( 2)( 0) Vector::operator [](int)
Proc Info [30] endref 25, int
22. ( 3)( 0) this Param Info [24] class*(file 0,index 4)
23. ( 3)( 0) i Param Info [ 3] int
24. ( 2)( 0) Vector::operator [](int)
End Info symref 21
25. ( 1)( 0) Vector End Info symref 4
26. ( 1)( -2) Proc Info [39] endref 29, class Reference
(file 2,index 2)
27. ( 2)( 0) Param Info [35] class Reference (file 2,index 2)
28. ( 1)( 0) End Info symref 26
29. ( 1)(0x400) __throw_Q16Vector4Size
Static RData [ 9] struct Const Array [(file 0,
aux 3)0-1:128] (file 0,index 2)
30. ( 1)(0x420) __throw_Q16Vector5Range
Static RData [ 9] struct Const Array [(file 0,
aux 3)0-1:128] (file 0,index 2)
31. ( 1)(0x1e0) f(void) Proc Text [64] endref 42, void
32. ( 2)(0x18) Block Text symref 41
33. ( 3)( -24) i Local Abs [ 3] int
34. ( 3)( -40) __current_context
Local Abs indexNil
35. ( 3)(0x2c) Block Text symref 40
36. ( 4)(0x2c) Block Text symref 39
37. ( 5)( -16) v Local Abs [16] class(file 0,index 4)
38. ( 4)(0x9c) End Text symref 36
39. ( 3)(0x9c) End Text symref 35
40. ( 2)(0x19c) End Text symref 32
41. ( 1)(0x1a4) f(void) End Text symref 31
42. ( 1)(0x384) main Proc Text [66] endref 46, int
43. ( 2)(0x10) Block Text symref 45
44. ( 2)(0x18) End Text symref 43
45. ( 1)(0x24) main End Text symref 42
46. ( 1)(0x34) Vector::Vector(int)
Proc Text [68] endref 52, class Reference
(file 0,index 4)
47. ( 2)( 0x9) this Param Register [46] class* Const (file 0,index 4)
48. ( 2)(0x10) i Param Abs [ 3] int
49. ( 2)(0x1c) Block Text symref 51
50. ( 2)(0x88) End Text symref 49
51. ( 1)(0xf0) Vector::Vector(int)
End Text symref 46
52. ( 1)(0x124) Vector::operator [](int)
Proc Text [71] endref 58, int
53. ( 2)(0x20) this Param Abs [46] class* Const (file 0,index 4)
54. ( 2)( 0x9) i Param Register [ 3] int
55. ( 2)(0x1c) Block Text symref 57
56. ( 2)(0x54) End Text symref 55
57. ( 1)(0xbc) Vector::operator [](int)
End Text symref 52
58. ( 0)( 0) exc.cxx End Text symref 0
17.3 Fortran
17.3.1 Common Data
See
Section 11.3.1.8
for related information.
Source Listing
comm.f:
C main program
INTEGER IND, CLASS(10)
REAL MARKS(50)
COMMON CLASS,MARKS,IND
CALL EVAL(5)
STOP
END
C
SUBROUTINE EVAL(PERF)
INTEGER PERF,JOB(10),PAR
REAL GRADES(50)
COMMON JOB,GRADES,PAR
RETURN
END
Symbol Table Contents
File 0 Local Symbols:
0. ( 0)( 0) comm.f File Text symref 13
1. ( 1)( 0) main$comm_ Proc Text [ 4] endref 6, btNil
2. ( 2)(0x2c) Block Text symref 5
3. ( 3)( 0) _BLNK__ Static Common [18] struct(file 1,index 1)
4. ( 2)(0x64) End Text symref 2
5. ( 1)(0x64) main$comm_ End Text symref 1
6. ( 1)(0x64) eval_ Proc Text [20] endref 12, btNil
7. ( 2)( 0x1) PERF Param VarRegister [ 3] 32-bit long
8. ( 2)( 0x8) Block Text symref 11
9. ( 3)( 0) _BLNK__ Static Common [22] struct(file 2,index 1)
10. ( 2)( 0xc) End Text symref 8
11. ( 1)(0x14) eval_ End Text symref 6
12. ( 0)( 0) comm.f End Text symref 0
File 1 Local Symbols:
0. ( 0)( 0) _BLNK__ File Text symref 7
1. ( 1)(0xf4) _BLNK__ Block Common symref 6
2. ( 2)( 0) CLASS Member Info [ 4] 32-bit long
Array [(file 0, aux 6)1-10:4]
3. ( 2)(0x140) MARKS Member Info [ 9] float
Array [(file 0, aux 6)1-50:4]
4. ( 2)(0x780) IND Member Info [14] 32-bit long
5. ( 1)( 0) End Common symref 1
6. ( 0)( 0) _BLNK__ End Text symref 0
File 2 Local Symbols:
0. ( 0)( 0) _BLNK__ File Text symref 7
1. ( 1)(0xf4) _BLNK__ Block Common symref 6
2. ( 2)( 0) JOB Member Info [ 4] 32-bit long
Array [(file 0, aux 6)1-10:4]
3. ( 2)(0x140) GRADES Member Info [ 9] float
Array [(file 0, aux 6)1-50:4]
4. ( 2)(0x780) PAR Member Info [14] 32-bit long
5. ( 1)( 0) End Common symref 1
6. ( 0)( 0) _BLNK__ End Text symref 0
Externals table:
0. (file 0) ( 0) MAIN__ Proc Text symref 1
1. (file 0) (0xf4) _BLNK__ Global Common indexNil
2. (file 0) ( 0) main$comm_ Proc Text symref 1
3. (file 0) (0x64) eval_ Proc Text symref 6
4. (file 0) ( 0) for_set_reentrancy
Proc Undefined indexNil
5. (file 0) ( 0) for_stop_core
Proc Undefined indexNil
6. (file 0) ( 0) _fpdata Global Undefined indexNil
***FILE DESCRIPTOR TABLE***
filename address vstamp -g sex lang flags
cbLine ---------------iBase/count----------------------------------
lnOffset sym line pd string opt aux rfd
comm.o:
comm.f 0x0000000000000000 0x030d 0 el Fortran readin
0 0 0 0 0 0 0 0
5 13 32 2 38 0 24 0
_BLNK__ 0x0000000000000000 0x030d 0 el Fortran merge
0 13 0 2 38 0 24 0
0 7 0 0 33 0 15 0
_BLNK__ 0x0000000000000000 0x030d 0 el Fortran merge
0 20 0 2 71 0 39 0
0 7 0 0 32 0 15 0
See
Section 11.3.1.9
for related information.
Source Listing
aent.f:
program entryp
print *, "In entryp, the main routine"
call anentry()
call anentry1(2,3)
call asubr()
print *, "exiting..."
end
subroutine asubr
real*4 areal /1.2345E-6/
print *, "In asubr"
return
entry anentry
print *, "In anentry"
return
entry anentry1(a,b)
a = 1
b = 2
print *, "In anentry1"
return
entry anentry2(b,a)
print *, "In anentry2"
return
entry anentry3
return
end
Symbol Table Contents
File 0 Local Symbols:
0. ( 0)( 0) aent.f File Text symref 23
1. ( 1)( 0) entryp_ Proc Text [ 4] endref 5, btNil
2. ( 2)( 0x2c) Block Text symref 4
3. ( 2)( 0xd0) End Text symref 2
4. ( 1)( 0xdc) entryp_ End Text symref 1
5. ( 1)( 0xdc) asubr_ Proc Text [ 6] endref 22, btNil
6. ( 2)( 0x1c) Block Text symref 21
7. ( 3)(0x400) AREAL Static Data [ 8] float
8. ( 3)(0x144) anentry_ Proc Text [ 9] endref -1, btNil
9. ( 4)( 0x1c) Block Text symref (indexNil)
10. ( 3)(0x1ac) anentry1_ Proc Text [11] endref -1, btNil
11. ( 4)( -104) A Param Var [ 8] float
12. ( 4)( -112) B Param Var [ 8] float
13. ( 4)( 0x24) Block Text symref (indexNil)
14. ( 3)(0x238) anentry2_ Proc Text [13] endref -1, btNil
15. ( 4)( -112) B Param Var [ 8] float
16. ( 4)( -104) A Param Var [ 8] float
17. ( 4)( 0x24) Block Text symref (indexNil)
18. ( 3)(0x2a8) anentry3_ Proc Text [15] endref -1, btNil
19. ( 4)( 0x1c) Block Text symref (indexNil)
20. ( 2)(0x1fc) End Text symref 6
21. ( 1)(0x20c) asubr_ End Text symref 5
22. ( 0)( 0) aent.f End Text symref 0
Externals table:
0. (file 0) ( 0) MAIN__ Proc Text symref 1
1. (file 0) ( 0) entryp_ Proc Text symref 1
2. (file 0) ( 0xdc) asubr_ Proc Text symref 5
3. (file 0) (0x1ac) anentry1_ Proc Text symref 10
4. (file 0) (0x144) anentry_ Proc Text symref 8
5. (file 0) ( 0) for_set_reentrancy
Proc Undefined indexNil
6. (file 0) ( 0) for_write_seq_lis
Proc Undefined indexNil
7. (file 0) (0x238) anentry2_ Proc Text symref 14
8. (file 0) (0x2a8) anentry3_ Proc Text symref 18
9. (file 0) ( 0) _fpdata Global Undefined indexNil
***PROCEDURE DESCRIPTOR TABLE***
name
address isym iline lnLow lnHigh regmask regoff fpoff fp
flags gpro lnOff iopt fregmask frgoff lcloff pc
aent.o:
aent.f [0 for 6]
entryp_
0x0000 1 0 1 9 0x04000000 -96 96 30
GPUSE NOSTK 8 0 -1 0x00000000 0 0 26
asubr_
0x00dc 5 55 11 33 0x04000200 -176 176 30
GPUSE NOSTK 8 8 -1 0x00000000 0 0 26
anentry_
0x0144 8 81 16 -1 0x04000200 -176 176 30
GPUSE NOSTK 8 12 -1 0x00000000 0 0 26
anentry1_
0x01ac 10 107 20 -1 0x04000200 -176 176 30
GPUSE NOSTK 8 16 -1 0x00000000 0 0 26
anentry2_
0x0238 14 142 26 -1 0x04000200 -176 176 30
GPUSE NOSTK 8 22 -1 0x00000000 0 0 26
anentry3_
0x02a8 18 170 30 -1 0x04000200 -176 176 30
GPUSE NOSTK 8 26 -1 0x00000000 0 0 26
See
Section 11.3.3.9
for related information.
Source Listing
arraydescs.f:
! -*- Fortran -*-
integer, allocatable, dimension(:,:) :: alloc_int_2d
real, pointer, dimension(:) :: pointer_real_1d
allocate(alloc_int_2d(10,20))
call zowie(alloc_int_2d)
end
contains
subroutine zowie(assumed_int_2d)
integer, dimension(:,:) :: assumed_int_2d
print *, assumed_int_2d
return
end subroutine
Symbol Table Contents
File 0 Local Symbols:
0. ( 0)( 0) arraydescs.f
File Text symref 43
1. ( 1)( 0) main$arraydescs_
Proc Text [ 4] endref 26, btNil
2. ( 2)( 0x40) $f90$f90_array_desc
Block Info symref 10
3. ( 3)( 0) dim Member Info [ 6] 8-bit int
4. ( 3)( 0x40) element_length
Member Info [ 3] 32-bit long
5. ( 3)( 0x80) ptr Member Info [ 8] float*
6. ( 3)(0x140) ies1 Member Info [ 3] 32-bit long
7. ( 3)(0x180) ub1 Member Info [ 3] 32-bit long
8. ( 3)(0x1c0) lb1 Member Info [ 3] 32-bit long
9. ( 2)( 0) $f90$f90_array_desc
End Info symref 2
10. ( 2)( 0x58) $f90$f90_array_desc
Block Info symref 21
11. ( 3)( 0) dim Member Info [ 6] 8-bit int
12. ( 3)( 0x40) element_length
Member Info [ 3] 32-bit long
13. ( 3)( 0x80) ptr Member Info [11] 32-bit long*
14. ( 3)(0x140) ies1 Member Info [ 3] 32-bit long
15. ( 3)(0x180) ub1 Member Info [ 3] 32-bit long
16. ( 3)(0x1c0) lb1 Member Info [ 3] 32-bit long
17. ( 3)(0x200) ies2 Member Info [ 3] 32-bit long
18. ( 3)(0x240) ub2 Member Info [ 3] 32-bit long
19. ( 3)(0x280) lb2 Member Info [ 3] 32-bit long
20. ( 2)( 0) $f90$f90_array_desc
End Info symref 10
21. ( 2)( 0x24) Block Text symref 25
22. ( 3)(0x480) POINTER_REAL_1D
Static Bss [8] struct(extended file 0,index 2)
23. ( 3)(0x3f0) ALLOC_INT_2D
Static Data [12] struct(file 0,index 10)
24. ( 2)(0x168) End Text symref 21
25. ( 1)(0x174) main$arraydescs_
End Text symref 1
26. ( 1)(0x174) zowie_ Proc Text [14] endref 42, btNil
27. ( 2)( 0x58) $f90$f90_array_desc
Block Info symref 38
28. ( 3)( 0) dim Member Info [ 6] 8-bit int
29. ( 3)( 0x40) element_length
Member Info [ 3] 32-bit long
30. ( 3)( 0x80) ptr Member Info [11] 32-bit long*
31. ( 3)(0x140) ies1 Member Info [ 3] 32-bit long
32. ( 3)(0x180) ub1 Member Info [ 3] 32-bit long
33. ( 3)(0x1c0) lb1 Member Info [ 3] 32-bit long
34. ( 3)(0x200) ies2 Member Info [ 3] 32-bit long
35. ( 3)(0x240) ub2 Member Info [ 3] 32-bit long
36. ( 3)(0x280) lb2 Member Info [ 3] 32-bit long
37. ( 2)( 0) $f90$f90_array_desc
End Info symref 27
38. ( 2)( 0x9) ASSUMED_INT_2D
Param VarRegister [16] struct(file 0,index 27)
39. ( 2)( 0x78) Block Text symref 41
40. ( 2)(0x214) End Text symref 39
41. ( 1)(0x240) zowie_ End Text symref 26
42. ( 0)( 0) arraydescs.f
End Text symref 0
See
Section 11.3.1.6
for related information.
Source Listing
a.f90:
module A
data PI /3.14159/
integer TEN
data TEN/10/
end
b.f90:
module B
use A, ONLY: BASE_PI => PI, TEN
data TWOPI /6.28318/
end
prog.f90:
program PROG
use A
use B, TWOPI2 => TWOPI
X = TWOPI2 / PI
Y = PI / BASE_PI
end
Symbol Table Contents
File 20 Local Symbols: 0. ( 0)( 0) a.f90 File Text symref 6 1. ( 1)( 0) A Module Info symref 5 2. ( 2)(140000010) PI Static Data [ 3] float 3. ( 2)(140000014) TEN Static Data [ 4] 32-bit long 4. ( 1)( 0) A End Info symref 1 5. ( 0)( 0) a.f90 End Text symref 0 File 21 Local Symbols: 0. ( 0)( 0) b.f90 File Text symref 9 1. ( 1)( 0) B Module Info symref 8 2. ( 2)( 0) A UseModule Info symref 6 3. ( 3)( PI) BASE_PI Rename Info isymNil 4. ( 3)( TEN) TEN Rename Info isymNil 5. ( 2)( 0) A End Info symref 2 6. ( 2)(140000018) TWOPI Static Data [2] float 7. ( 1)( 0) B End Info symref 1 8. ( 0)( 0) b.f90 End Text symref 0 File 22 Local Symbols: 0. ( 0)( 0) prog.f90 File Text symref 12 1. ( 1)(120001870) prog_ Proc Text [ 2] endref 11, btNil 2. ( 2)( 24) Block Text symref 10 3. ( 3)( 1) A UseModule Info isymNil 4. ( 3)( 1) B UseModule Info symref 7 5. ( 4)( TWOPI) TWOPI2 Rename Info isymNil 6. ( 3)( 0) B End Info symref 4 7. ( 3)(140000210) X Static Bss [ 4] float 8. ( 3)(140000214) Y Static Bss [ 4] float 9. ( 2)( 60) End Text symref 2 10. ( 1)( 6c) prog_ End Text symref 1 11. ( 0)( 0) prog.f90 File Text symref 0 Externals table: ... 29. (file 22) (120001870) prog_ Proc Text symref 1 ... 37. (file 20) (140000010) $a$pi_ Global Data [ 4] float 38. (file 20) (140000014) $a$ten_ Global Data [ 3] 32-bit long 39. (file 21) (140000018) $b$twopi_ Global Data [ 2] float ...
17.3.5 Contained Procedures in Fortran Modules
See
Section 11.3.1.6
for related information.
Source Listing
contain.f90:
module C
contains
subroutine BAR
print *, 1
end subroutine
end
Symbol Table Contents
File 0 Local Symbols: 0. ( 0)( 0) contain.f90 File Text symref 8 1. ( 1)( 0) C Module Info symref 7 2. ( 2)( 0) bar_ Proc Text [ 4] endref 6, btNil 3. ( 3)(0x10) Block Text symref 6 4. ( 3)(0x4c) End Text symref 3 5. ( 2)(0x58) bar_ End Text symref 2 6. ( 1)( 0) C End Info symref 1 7. ( 0)( 0) contain.f90 End Text symref 0 Externals table: 0. (file 0) ( 0) $c$bar_ Proc Text symref 1
17.3.6 Interface Declarations in Fortran Modules
See
Section 11.3.1.6
for related information.
Source Listing
iface.f90:
module A
real F
interface
subroutine FOO(A)
end subroutine
end interface
end module
Symbol Table Contents
File 0 Local Symbols: 0. ( 0)( 0) iface.f90 File Text symref 8 1. ( 1)( 0) A Module Info symref 7 2. ( 2)( 0) F Static Bss [ 3] float 3. ( 2)( -2) foo_ Proc Info [ 4] endref 6, btNil 4. ( 3)( 0) A Param VarRegister [ 6] float 5. ( 2)( 0) foo_ End Info symref 3 6. ( 1)( 0) A End Info symref 1 7. ( 0)( 0) iface.f90 End Text symref 0 Externals table: 0. (file 0) ( 0) $a$f_ Global Bss [ 3] float
17.3.7 Generic Interfaces in Fortran Modules
See
Section 11.3.1.6.2
for related information.
Source Listing
gen.f90:
module GEN
interface SUB
subroutine SUB1(I)
end subroutine
subroutine SUB2(R)
end subroutine
end interface
end module
Symbol Table Contents
File 0 Local Symbols: 0. ( 0)( 0) gen.f90 File Text symref 12 1. ( 1)( 0) GEN Module Info symref 11 2. ( 2)( 0) sub_ Interface Info symref 10 3. ( 3)( -2) sub1_ Proc Info [ 4] endref 6, btNil 4. ( 4)( 0) I Param VarRegister [ 6] integer*4 5. ( 3)( 0) sub1_ End Info symref 3 6. ( 3)( -2) sub2_ Proc Info [ 7] endref 9, btNil 7. ( 4)( 0) R Param VarRegister [ 9] float 8. ( 3)( 0) sub2_ End Info symref 6 9. ( 2)( 0) sub_ End Info symref 2 10. ( 1)( 0) GEN End Info symref 1 11. ( 0)( 0) gen.f90 End Text symref 0
See
Section 11.3.3.13
for related information.
Source Listing
program sets(input,output); type digitset=set of 0..9; var odds,evens:digitset; begin odds:=[1,3,5,7,9]; evens:=[0,2,4,6,8]; end.
Symbol Table Contents
File 0 Local Symbols: 0. ( 0)( 0) set.p File Text symref 10 1. ( 1)(0x50) $dat Static SBss indexNil 2. ( 1)( 0) main Proc Text [ 8] endref 9, btNil 3. ( 2)( 0x4) Block Text symref 8 4. ( 3)( 0) digitset Typdef Info [16] set of range int (0..9) 5. ( 3)(-8) odds Local Abs [16] set of range int (0..9) 6. ( 3)(-16) evens Local Abs [16] set of range int (0..9) 7. ( 2)(0x1c) End Text symref 3 8. ( 1)(0x24) main End Text symref 2 9. ( 0)( 0) set.p End Text symref 0
See
Section 11.3.3.12
for related information.
Source Listing
subrange.p: program years(input,output); type century=0..99; var year:century; begin readln(year); end.
Symbol Table Contents
File 0 Local Symbols: 0. ( 0)( 0) subrange.p File Text symref 9 1. ( 1)(0xc0) $dat Static SBss indexNil 2. ( 1)( 0) main Proc Text [ 8] endref 8, btNil 3. ( 2)(0x10) Block Text symref 7 4. ( 3)( 0) century Typdef Info [10] range0..99 of(file 0, index 2): 8 5. ( 3)(-8) year Local Abs [10] range0..99 of(file 0, index 2): 8 6. ( 2)(0x68) End Text symref 3 7. ( 1)(0x74) main End Text symref 2 8. ( 0)( 0) subrange.p End Text symref 0
See
Section 11.3.3.11
for related information.
Source Listing
variant.p:
program variant(input,output);
type employeetype=(h,s,m);
employeerecord=record
id:integer;
case status: employeetype of
h: (rate:real;
hours:integer;);
s: (salary:real);
m: (profit:real);
end; { record }
var employees:array[1..100] of employeerecord;
begin
employees[1].id:=1;
employees[1].profit:=0.06;
end.
Symbol Table Contents
File 0 Local Symbols
0. (0)( 0) variant.p File Text symref 28
1. (1)( 0) VARIANT StaticProc Text [2] endref 27, btNil
2. (2)( 0) EMPLOYEETYPE
Block Info symref 7
3. (3)( 0) H Member Info [0] btNil
4. (3)( 0x1) S Member Info [0] btNil
5. (3)( 0x2) M Member Info [0] btNil
6. (2)( 0) EMPLOYEETYPE
End Info symref 2
7 (2)(0x10) EMPLOYEERECORD
Block Info symref 23
8 (3)( 0) ID Member Info [1] int
9 (3)(0x20) STATUS Member Info [5] enum(file 1,index 2)
10. (3)( 0x9) Block Variant symref 22
11. (4)( 0xc) Block Info symref 15
12. (5)(0x40) RATE Member Info [11] float
13. (5)(0x60) HOURS Member Info [1] int
14 (4)( 0) End Info symref 11
15. (4)(0x11) Block Info symref 18
16. (5)(0x40) SALARY Member Info [11] float
17. (4)( 0) End Info symref 15
18. (4)(0x16) Block Info symref 21
19. (5)(0x40) PROFIT Member Info [11] float
20. (4)( 0) End Info symref 18
21. (3)( 0x9) End Variant symref 10
22. (2)( 0) EMPLOYEERECORD
End Info symref 7
23. (2)(0x18) Block Text symref 26
24. (3)(-1600) EMPLOYEES Local Abs [32] Array [file 1,aux 27)1-100:128] of
struct (file 1,index 7)
25. (2)(0x30) End Text symref 23
26. (1)(0x40) VARIANT End Text symref 1
27. (0)( 0) variant.p End Text symref 0