Separate data and function address spaces
Chip Salzenberg
chip at ateng.com
Wed Nov 15 03:41:51 AEST 1989
According to cpcahil at virtech.uucp (Conor P. Cahill):
>According to chip at ateng.com (Chip Salzenberg):
>> The '286 and '386 processors, in protected mode, do not permit
>> program execution from any data segment. This restriction can be
>> bypassed only by the subterfuge of pointing two segment descriptors
>> at the same piece of memory.
>
>I don't know what unix you are using...
Conor then proceeds to describe how "real" SysV for the '386 actually does
perform the two-descriptors-pointing-at-the-same-memory trick.
Unlike SysV, SCO Xenix/286 and Xenix/386 versions 2.2 and 2.3 create
disjoint code and data segments. The exceptions are called "impure"
binaries. I've never seen impure binaries except for the '286/186/8086,
and such 16-bit binaries limit code and data to a total of 64K.
Incidentally, Xenix/386 2.3 can execute COFF binaries without conversion.
Perhaps Xenix would give them executable data...
--
You may redistribute this article only to those who may freely do likewise.
Chip Salzenberg at A T Engineering; <chip at ateng.com> or <uunet!ateng!chip>
More information about the Comp.lang.c
mailing list