Problem with xstr

The Beach Bum jfh at rpp386.Dallas.TX.US
Wed Sep 21 10:23:58 AEST 1988


In article <145 at taux02.UUCP> amos at taux02.UUCP (Amos Shapir) writes:
>Unless you use a pdp11 with separate  I/D space, the solution is to just
>throw out all  the xstr stuff from your makefiles,  and compile normally
>instead.

xstr is a loser in a separated i & d space system.  xstr places the
strings into the pure text segment which is not addressable from d-space.

>Xstr is a hack for putting  strings, which are supposed to be read-only,
>into the executable's  text (code) space. This makes more  room for data
>on  machines  with  limited  address space.  On  32-bit  machines,  this
>approach is obsolete and causes more trouble than benefit.

it also makes the strings shared text.  all constants should be put into
a constants section and shared [ hmmm.  found a use for "const" !!! ].
this is a real win for programs which have considerable amounts of constant
character data.
-- 
John F. Haugh II (jfh at rpp386.Dallas.TX.US)                   HASA, "S" Division

      "Why waste negative entropy on comments, when you could use the same
                   entropy to create bugs instead?" -- Steve Elias



More information about the Comp.unix.wizards mailing list