gpc-20030323 testsuite with alignment

Frank Heckenbach frank at
Sun Mar 30 21:00:57 CEST 2003

Adriaan van Os wrote:

> Frank Heckenbach wrote:
> > Adriaan van Os wrote:
> >
> >> I ran the gpc testsuite, with the added option
> >> EXTRA_TEST_PFLAGS="--maximum-field-alignment=8".
> >>
> > Interesting idea, but you can't actually expect it to work. The
> > option affects all structures, including those used in the RTS and
> > defined in gpc.pas or built-in. This includes the internal file
> > structure which seems to be responsible for most of the failures.
> >
> > I expected the option to be used for specific declarations (system
> > interfaces etc.). Of course, this means that the command-line option
> > is not really a good idea (for now).
> >
> > To solve this, we could deactivate the option while defining the
> > bulit-in structures (in the compiler), and while compiling gpc.pas
> > (by putting a `0' compiler directive in it -- you might want to try
> > this, this might fix some of the failures, but probably not msot of
> > them since the file structure is built-in).
> >
> > Still, there will be problems if (a) some regular unit is compiled
> > with this option and its users not or vice versa, (b) some
> > ("non-system") C interface unit is compiled with it, (c) code that
> > relies on specific alignment is compiled with it. This might not be
> > too many problems, but might still be some failures when running the
> > test suite with `--maximum-field-alignment=8'.
> >
> > Still I wonder if the command-line option is actually useful, and if
> > we shouldn't drop it and only allow it as a compiler directive.
> Running the testsuite with EXTRA_TEST_PFLAGS="--pack-struct" causes 
> similar problems .... Dropping both --maximum-field-alignment and 
> --pack-struct as command-line options is a solution (and I don't object 
> if they are dropped) but my personal preference is in keeping them and 
> adding compiler directives to compiler-internal and runtime-library 
> data structures.
> I recall how we defined BP compatibility ....

Right. I'm doing this now, so in the next release the test suite
should work with these options.


Frank Heckenbach, frank at,, 7977168E
GPC To-Do list, latest features, fixed bugs:
GPC download signing key: 51FF C1F0 1A77 C6C2 4482  4DDC 117A 9773 7F88 1707

More information about the Gpc mailing list