literal pool support

David Edelsohn dje@watson.ibm.com
Wed Jul 7 20:36:00 GMT 1999


	One does not write to the literal pool, but most systems running
on S/390 do not prevent one from doing so.  The literal pool is no more
protected than regular data, so why not simply treat it as regular data.

	I am not suggesting creating a separate literal pool area, I am
suggesting placing the literals in the data.  GCC on AIX places literals
directly in the TOC.  XLC creates a static pool and constants pool with
addressibility to those pools provided through the TOC.

	Unlike a TOC or GOT, S/390 frequently has a separate data area for
each procedure with addressibility provided by the calling procedure.  The
data area contains the addresses of the actual global data and local
variables.  One could place the literals with the procedures addresses, if
that is how the i370 port works.  12-bits is not a lot of addressibility,
but this is 12-bits per procedure, not per executable (like TOC and GOT).

	Also, using the data area pool, GCC can merge and re-use literals
for the entire procedure, not just for each code page.

	Nothing I have suggested requires the new PC-relative branching.
I have not broken GCC for S/370 and current S/390 users.

David


More information about the Gcc-patches mailing list