Re: RFR: 8200203: Missing platform definitions for ia64

2018-03-26 Thread Erik Joelsson

On 2018-03-26 00:44, Magnus Ihse Bursie wrote:


On 2018-03-26 03:06, John Paul Adrian Glaubitz wrote:

On 03/26/2018 08:08 AM, David Holmes wrote:
I also wonder if the values here can be reliably obtained via 
uname/sysconf
or some such utility so that we don't have to list every single 
platform

individually?

I think autoconf normally has support for this, yes. It's rather unusual
having to add targets manually. But you will need the mapping to 
VAR_CPU,

for example. I will have a look at it anyway.
You can consider platform.m4 (amongst other thing) to be a 
"translation" between whatever autoconf calls a platform, and what 
OpenJDK has traditionally used. For some platforms, this is a 
no-brainer, but for other, there are unfortunately multiple, 
well-accepted names (amd64, x86_64, x64), and the choice OpenJDK made 
in the past was not always aligned with the uname/sysconf/autoconf name.


Despite our best efforts, we are still plagued by having different 
names in different places.


We could perhaps try to make a "generic" section that maps OpenJDK 
names and values directly to what's given by the system, and use it 
whereever it applies. I'm not sure how to extract the endianness, 
though..


I think this makes sense. Couldn't we just ask the preprocessor about 
32/64-bit and endian order? I realize there will be some ordering 
complications for the tests in configure so not completely trivial to 
implement.


/Erik


Re: RFR: 8200203: Missing platform definitions for ia64

2018-03-26 Thread John Paul Adrian Glaubitz
On 03/26/2018 04:44 PM, Magnus Ihse Bursie wrote:
>> For the time being, it would be nice if I can get this and a second follow-up
>> change for ia64 merged so downstream (currently Debian and Gentoo for ia64)
>> doesn't have to carry any additional patches anymore.
> Your patch looks good to me.

Thank you. I just pushed it. I hope I did everything correctly being it
my second push on my own. Added Thomas and you as reviewers and ran
"hg jcheck" before pushing.

Still a bit nervous when pushing to master.

Thanks,
Adrian

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaub...@debian.org
`. `'   Freie Universitaet Berlin - glaub...@physik.fu-berlin.de
  `-GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913


Re: RFR: 8200203: Missing platform definitions for ia64

2018-03-26 Thread Magnus Ihse Bursie



On 2018-03-26 03:06, John Paul Adrian Glaubitz wrote:

On 03/26/2018 08:08 AM, David Holmes wrote:

Everytime I see these zero-only platform definitions it makes we think we really
should have these isolated into a zero-specific file. At the moment this can
paint a false picture that all these platforms have full OpenJDK ports 
available.

Is that really the case though? If someone is reading the platform.m4 file, they
might think that but simply trying to build the server variant for ia64 would
fail very quickly anyway and people would realize it's not supported.

In the end, I think the extended portability OpenJDK highly outweighs your
reservations above. Someone who doesn't understand the difference between Zero
and the official ports, is also unlikely to try building OpenJDK from source
themselves.
I agree. I don't think it's a problem that we list the zero platforms in 
platform.m4.



I also wonder if the values here can be reliably obtained via uname/sysconf
or some such utility so that we don't have to list every single platform
individually?

I think autoconf normally has support for this, yes. It's rather unusual
having to add targets manually. But you will need the mapping to VAR_CPU,
for example. I will have a look at it anyway.
You can consider platform.m4 (amongst other thing) to be a "translation" 
between whatever autoconf calls a platform, and what OpenJDK has 
traditionally used. For some platforms, this is a no-brainer, but for 
other, there are unfortunately multiple, well-accepted names (amd64, 
x86_64, x64), and the choice OpenJDK made in the past was not always 
aligned with the uname/sysconf/autoconf name.


Despite our best efforts, we are still plagued by having different names 
in different places.


We could perhaps try to make a "generic" section that maps OpenJDK names 
and values directly to what's given by the system, and use it whereever 
it applies. I'm not sure how to extract the endianness, though..



For the time being, it would be nice if I can get this and a second follow-up
change for ia64 merged so downstream (currently Debian and Gentoo for ia64)
doesn't have to carry any additional patches anymore.

Your patch looks good to me.

/Magnus


Thanks,
Adrian





Re: RFR: 8200203: Missing platform definitions for ia64

2018-03-26 Thread Thomas Stüfe
On Mon, Mar 26, 2018 at 3:19 AM, David Holmes 
wrote:

> On 26/03/2018 11:06 AM, John Paul Adrian Glaubitz wrote:
>
>> On 03/26/2018 08:08 AM, David Holmes wrote:
>>
>>> Everytime I see these zero-only platform definitions it makes we think
>>> we really
>>> should have these isolated into a zero-specific file. At the moment this
>>> can
>>> paint a false picture that all these platforms have full OpenJDK ports
>>> available.
>>>
>>
>> Is that really the case though? If someone is reading the platform.m4
>> file, they
>> might think that but simply trying to build the server variant for ia64
>> would
>> fail very quickly anyway and people would realize it's not supported.
>>
>
> It's not so much that (though there have been cases!) but people just
> looking in that file can't tell a full platform from a zero-only platform.
> The general rule is that OpenJDK doesn't accept platform specific patches
> unless there is a fully supported port of that platform. But zero is the
> exception to that rule. So I just think, as a separate RFE, it would be
> good to split these out into platforms-zero.m4 which can then be included
> in platforms.m4
>
>
This sounds reasonable.


> In the end, I think the extended portability OpenJDK highly outweighs your
>> reservations above. Someone who doesn't understand the difference between
>> Zero
>> and the official ports, is also unlikely to try building OpenJDK from
>> source
>> themselves.
>>
>> I also wonder if the values here can be reliably obtained via
>>> uname/sysconf
>>> or some such utility so that we don't have to list every single platform
>>> individually?
>>>
>>
>> I think autoconf normally has support for this, yes. It's rather unusual
>> having to add targets manually. But you will need the mapping to VAR_CPU,
>> for example. I will have a look at it anyway.
>>
>> For the time being, it would be nice if I can get this and a second
>> follow-up
>> change for ia64 merged so downstream (currently Debian and Gentoo for
>> ia64)
>> doesn't have to carry any additional patches anymore.
>>
>
> I don't have a concern with this going in as-is for now. But wait for
> Magnus or Erik to give the okay.
>
> Thanks,
> David
>
> Thanks,
>> Adrian
>>
>>
Thanks, Thomas


Re: RFR: 8200203: Missing platform definitions for ia64

2018-03-26 Thread Thomas Stüfe
Hi Adrian,

On Sun, Mar 25, 2018 at 1:14 PM, John Paul Adrian Glaubitz <
glaub...@physik.fu-berlin.de> wrote:

> Hi!
>
> Please review this small change to the build system which adds the
> platform definitions for ia64. This is one of two changes that is
> necessary to get OpenJDK to build on ia64 (Zero variant).
>
> Thanks,
> Adrian
>
> > [1] http://cr.openjdk.java.net/~glaubitz/8200203/webrev.01/
>
>
Looks good to me.

..Thomas


> --
>  .''`.  John Paul Adrian Glaubitz
> : :' :  Debian Developer - glaub...@debian.org
> `. `'   Freie Universitaet Berlin - glaub...@physik.fu-berlin.de
>   `-GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
>


Re: RFR: 8200203: Missing platform definitions for ia64

2018-03-25 Thread David Holmes

On 26/03/2018 11:06 AM, John Paul Adrian Glaubitz wrote:

On 03/26/2018 08:08 AM, David Holmes wrote:

Everytime I see these zero-only platform definitions it makes we think we really
should have these isolated into a zero-specific file. At the moment this can
paint a false picture that all these platforms have full OpenJDK ports 
available.


Is that really the case though? If someone is reading the platform.m4 file, they
might think that but simply trying to build the server variant for ia64 would
fail very quickly anyway and people would realize it's not supported.


It's not so much that (though there have been cases!) but people just 
looking in that file can't tell a full platform from a zero-only 
platform. The general rule is that OpenJDK doesn't accept platform 
specific patches unless there is a fully supported port of that 
platform. But zero is the exception to that rule. So I just think, as a 
separate RFE, it would be good to split these out into platforms-zero.m4 
which can then be included in platforms.m4



In the end, I think the extended portability OpenJDK highly outweighs your
reservations above. Someone who doesn't understand the difference between Zero
and the official ports, is also unlikely to try building OpenJDK from source
themselves.


I also wonder if the values here can be reliably obtained via uname/sysconf
or some such utility so that we don't have to list every single platform
individually?


I think autoconf normally has support for this, yes. It's rather unusual
having to add targets manually. But you will need the mapping to VAR_CPU,
for example. I will have a look at it anyway.

For the time being, it would be nice if I can get this and a second follow-up
change for ia64 merged so downstream (currently Debian and Gentoo for ia64)
doesn't have to carry any additional patches anymore.


I don't have a concern with this going in as-is for now. But wait for 
Magnus or Erik to give the okay.


Thanks,
David


Thanks,
Adrian



Re: RFR: 8200203: Missing platform definitions for ia64

2018-03-25 Thread John Paul Adrian Glaubitz
On 03/26/2018 08:08 AM, David Holmes wrote:
> Everytime I see these zero-only platform definitions it makes we think we 
> really
> should have these isolated into a zero-specific file. At the moment this can
> paint a false picture that all these platforms have full OpenJDK ports 
> available.

Is that really the case though? If someone is reading the platform.m4 file, they
might think that but simply trying to build the server variant for ia64 would
fail very quickly anyway and people would realize it's not supported.

In the end, I think the extended portability OpenJDK highly outweighs your
reservations above. Someone who doesn't understand the difference between Zero
and the official ports, is also unlikely to try building OpenJDK from source
themselves.

> I also wonder if the values here can be reliably obtained via uname/sysconf
> or some such utility so that we don't have to list every single platform
> individually?

I think autoconf normally has support for this, yes. It's rather unusual
having to add targets manually. But you will need the mapping to VAR_CPU,
for example. I will have a look at it anyway.

For the time being, it would be nice if I can get this and a second follow-up
change for ia64 merged so downstream (currently Debian and Gentoo for ia64)
doesn't have to carry any additional patches anymore.

Thanks,
Adrian

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaub...@debian.org
`. `'   Freie Universitaet Berlin - glaub...@physik.fu-berlin.de
  `-GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913


Re: RFR: 8200203: Missing platform definitions for ia64

2018-03-25 Thread David Holmes

Hi Adrian,

On 25/03/2018 9:14 PM, John Paul Adrian Glaubitz wrote:

Hi!

Please review this small change to the build system which adds the
platform definitions for ia64. This is one of two changes that is
necessary to get OpenJDK to build on ia64 (Zero variant).

Thanks,
Adrian


[1] http://cr.openjdk.java.net/~glaubitz/8200203/webrev.01/


Everytime I see these zero-only platform definitions it makes we think 
we really should have these isolated into a zero-specific file. At the 
moment this can paint a false picture that all these platforms have full 
OpenJDK ports available.


I also wonder if the values here can be reliably obtained via 
uname/sysconf or some such utility so that we don't have to list every 
single platform individually?


Thanks,
David


RFR: 8200203: Missing platform definitions for ia64

2018-03-25 Thread John Paul Adrian Glaubitz
Hi!

Please review this small change to the build system which adds the
platform definitions for ia64. This is one of two changes that is
necessary to get OpenJDK to build on ia64 (Zero variant).

Thanks,
Adrian

> [1] http://cr.openjdk.java.net/~glaubitz/8200203/webrev.01/

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaub...@debian.org
`. `'   Freie Universitaet Berlin - glaub...@physik.fu-berlin.de
  `-GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913