[fpc-devel] Re. z370 Cross Compilation, Pass 2 of ....

Mark Morgan Lloyd markMLl.fpc-devel at telemetry.co.uk
Sun Sep 1 19:40:38 CEST 2013


Bernd Oppolzer wrote:

> only the first step - node tree - is platform independant, and
> the translations from there is already CPU specific - oh, I see,
> it's written there - I looked at the word "independant" in the 
> paranthese - my fault ...
> 
> Sorry for that ...
> 
> Then the main effort is to understand what the contents of the node tree 
> mean
> and to build another variant of step 2 (for z-Arch).

At this point I'd throw in that one of the things the higher levels of 
the compiler knows is the overall properties of the registers, i.e. 
things like which ones are available for procedure parameters. This is 
one of the things that the lower level has to specify, so the 
lower-level units aren't there solely to do a macro-style substitution 
converting the compiler's internal representation to a sequence of 
assembler lines.

The corollary of this is that it's fairly common for a new target CPU to 
necessitate higher-level changes, and these then have to be propagated 
to all of the other targets. Which is why it's important to keep people 
like Florian and Jonas happy :-)

-- 
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]



More information about the fpc-devel mailing list