> On Dec 15, 2020, at 9:06 AM, Maciej W. Rozycki <ma...@linux-mips.org> wrote:
>
> On Tue, 15 Dec 2020, Martin Liška wrote:
>
>> If I see correctly, starting from this revision I can't compile a cross
>> compiler of x86_64-linux-gnu:
>>
>> ../configure --target=pdp11-aout --disable-bootstrap --enable-languages=c,c++
>> --disable-multilib --enable-obsolete
PDP11 doesn't do C++, there isn't any way to do that with aout that I have seen
(no named section support). There's been some experimental work on ELF for
pdp11 (!) which should make this possible but I haven't tried that yet.
>
> Thanks for the heads-up and the details of the configuration, and sorry
> for the breakage.
> ...
>
>> Can you please take a look?
>
> I'm fairly sure this is due to the difference in TARGET_SUPPORTS_WIDE_INT
> with the VAX backend vs the PDP-11 one. I have an idea how this should be
> addressed and will be implementing it shortly.
What's the difference? pdp11 does support wide int.
> NB the backend fails `-Werror' compilation:
>
> In file included from ./tm.h:18,
> from .../gcc/backend.h:28,
> from .../gcc/varasm.c:31:
> .../gcc/varasm.c: In function 'void assemble_zeros(long unsigned int)':
> .../gcc/config/pdp11/pdp11.h:622:20: error: format '%o' expects argument of
> type 'unsigned int', but argument 3 has type 'long unsigned int'
> [-Werror=format=]
> 622 | fprintf (FILE, "\t.blkb\t%o\n", (SIZE) & 0xffff); \
> | ^~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~
> | |
> | long unsigned int
>
> etc., so that has to be disabled. This may be with 64-bit hosts only, I'm
> not sure, however the way varargs are handled means the issue will likely
> cause a broken compiler to be built if the warning is ignored, at least
> with some hosts.
>
> Paul, can you please look into it sometime?
Will do, thanks.
paul