|
From: Thomas,Stephen <ste...@su...> - 2003-04-14 07:58:55
|
Apparently, the e_flags field of the ELF Header structure in ELF files =
is used by SH architectures to indicate the CPU type. The lower 5 bits =
have the following meaning:
0 =3D unknown CPU type
1 =3D SH1
2 =3D SH2
3 =3D SH3
5 =3D SH3 with DSP
8 =3D SH3E
9 =3D SH4
10 =3D SH5
The e_flags field is designed to hold architecture specific info, but =
other architectures don't appear to use it in quite the same way, i.e. =
to indicate different CPU types.
Does anybody know why SH uses e_flags in this way?
The problem I have is in generating & interpreting core files. When the =
kernel (V2.4)generates an ELF core dump, it just sets e_flags to 0 (hard =
coded constant) & dumps it. So to get it to generate a valid SH5 core =
dump, I need to modify generic code. There are similar problems with the =
gdb 'gcore' command.
Steve Thomas
SuperH (UK) Ltd
|