[fpc-devel] On a port of Free Pascal to the IBM 370

michael.vancanneyt at wisa.be michael.vancanneyt at wisa.be
Wed Jan 18 11:23:25 CET 2012

On Wed, 18 Jan 2012, Tomas Hajny wrote:

> On Wed, January 18, 2012 10:15, michael.vancanneyt at wisa.be wrote:
>> On Wed, 18 Jan 2012, Michael Schnell wrote:
>>> AFAI learned:
>>> I suppose the code generator should be doable, regarding that there
>>> already
>>> are several supported CPUs. At least a working compiler might come into
>>> existence in a decent amount of time, adding optimizations is another
>>> project.
>>> OTOH I suppose that a porting the RTL to a mainframe OS will not be easy
>>> and
>>> without this the compiler is quite useless.
>> I do not think it is more difficult than any other OS.
> ...except for the EBCDIC stuff, because the common parts of our RTL assume
> ASCII in many places (most of them probably not that difficult to fix by
> adding some platform specific constants changing the behaviour from ASCII
> only to consider EBCDIC too, but scattered around many places and thus
> difficult to find). That doesn't mean it shouldn't be doable, of course,
> it will just require debugging even parts which didn't have to be touched
> during ports to other operating systems.

? It just means you must convert ascii to ebcdic in OS calls that require
strings. All these calls must be re-implemented anyway, so a generic routine
to do this conversion seems like the obvious path. I doubt this will be the
real bottleneck :-)

As for using Linux: I have no idea how this works in practice, so I can't
comment on that. I know that people here use Hercules inside linux to
develop for zSeries, but then again running a linux inside that seems a bit 
like overkill :-)


More information about the fpc-devel mailing list