Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-17 Thread Paul Sandoz
On Wed, 17 Nov 2021 19:21:39 GMT, Paul Sandoz  wrote:

>>> @mcimadamore Thanks!
>>> 
>>> @PaulSandoz I'll keep this PR open until after the integration is done, and 
>>> check if or what parts are still needed after that. I don't want to mess up 
>>> your integration with trivia like this. (Had I realized the bad timing I 
>>> would have waited before opening this PR)
>> 
>> Thanks, integration should happen to today, then i can help guide you on 
>> what to update.
>
>> @PaulSandoz @mcimadamore Would you be ok with me pushing this now?
> 
> Specifically for the `*Vector.java` classes you to modify the 
> [X-Vector.java.template](https://github.com/openjdk/jdk/blob/master/src/jdk.incubator.vector/share/classes/jdk/incubator/vector/X-Vector.java.template#L5396).
> 
> Then run 
> [gen-src.sh](https://github.com/openjdk/jdk/blob/master/src/jdk.incubator.vector/share/classes/jdk/incubator/vector/gen-src.sh)
>  which will generate the `*Vector.java`. We need to integrate this into the 
> build system but it always gets bumped down in priority.

> @PaulSandoz Oh, I was not even aware of that. That sounds like quite an easy 
> fix for me. Is there an JBS issue on this?

There is now :-) I just created one:

  https://bugs.openjdk.java.net/browse/JDK-8277349

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-17 Thread Magnus Ihse Bursie
On Wed, 17 Nov 2021 15:11:24 GMT, Maurizio Cimadamore  
wrote:

>> So the refresh is still upcoming? Sorry, I thought it was pushed last week. 
>> When it is pushed, I'll merge in master and the duplicated changes will just 
>> be removed from the PR.
>
>> So the refresh is still upcoming? Sorry, I thought it was pushed last week. 
>> When it is pushed, I'll merge in master and the duplicated changes will just 
>> be removed from the PR.
> 
> There are _two_ refreshes:
> 
> * foreign API refresh: https://git.openjdk.java.net/jdk/pull/5907
> * vector API refresh: https://git.openjdk.java.net/jdk/pull/5873
> 
> Your patch covers both vector API and foreign API, but these APIs have 
> independent JEPs so their integration schedule differs. The vector API 
> refresh was integrated just few days ago, while the foreign API refresh will 
> hopefully be integrated soon (but JEP for that is still not targeted to 18).

@mcimadamore I see. Sorry for my confusion. :-( Maybe I should split this in 
two PRs, then...

@PaulSandoz  Oh, I was not even aware of that. That sounds like quite an easy 
fix for me. Is there an JBS issue on this?

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-17 Thread Paul Sandoz
On Fri, 12 Nov 2021 17:01:38 GMT, Paul Sandoz  wrote:

>>> > You could also do this directly in the Panama repo branches. I'll 
>>> > volunteer to help, if you want.
>>> 
>>> I'll run the script on the PR I've submitted for the Foreign API, and I 
>>> will update that one - thanks. Perhaps @PaulSandoz can do the same for the 
>>> Vector API refresh?
>> 
>> Done - the jdk.incubator.foreign changes are now part of 
>> https://github.com/openjdk/jdk/pull/5907
>
>> @mcimadamore Thanks!
>> 
>> @PaulSandoz I'll keep this PR open until after the integration is done, and 
>> check if or what parts are still needed after that. I don't want to mess up 
>> your integration with trivia like this. (Had I realized the bad timing I 
>> would have waited before opening this PR)
> 
> Thanks, integration should happen to today, then i can help guide you on what 
> to update.

> @PaulSandoz @mcimadamore Would you be ok with me pushing this now?

Specifically for the `*Vector.java` classes you to modify the 
[X-Vector.java.template](https://github.com/openjdk/jdk/blob/master/src/jdk.incubator.vector/share/classes/jdk/incubator/vector/X-Vector.java.template#L5396).

Then run 
[gen-src.sh](https://github.com/openjdk/jdk/blob/master/src/jdk.incubator.vector/share/classes/jdk/incubator/vector/gen-src.sh)
 which will generate the `*Vector.java`. We need to integrate this into the 
build system but it always gets bumped down in priority.

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-17 Thread Maurizio Cimadamore
On Wed, 17 Nov 2021 14:56:19 GMT, Magnus Ihse Bursie  wrote:

> So the refresh is still upcoming? Sorry, I thought it was pushed last week. 
> When it is pushed, I'll merge in master and the duplicated changes will just 
> be removed from the PR.

There are _two_ refreshes:

* foreign API refresh: https://git.openjdk.java.net/jdk/pull/5907
* vector API refresh: https://git.openjdk.java.net/jdk/pull/5873

Your patch covers both vector API and foreign API, but these APIs have 
independent JEPs so their integration schedule differs. The vector API refresh 
was integrated just few days ago, while the foreign API refresh will hopefully 
be integrated soon (but JEP for that is still not targeted to 18).

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-17 Thread Magnus Ihse Bursie
On Thu, 11 Nov 2021 14:50:43 GMT, Magnus Ihse Bursie  wrote:

> I ran bin/blessed-modifier-order.sh on source owned by Project Panama. This 
> scripts verifies that modifiers are in the "blessed" order, and fixes it 
> otherwise. I have manually checked the changes made by the script to make 
> sure they are sound.
> 
> In this case, while the script did into the "correct" thing, it turns out 
> that the method signatures in 
> `src/jdk.incubator.vector/share/classes/jdk/incubator/vector` has some room 
> for improvement... The files contains method headers which look like this:
> 
> 
> final @Override
> @ForceInline
> long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override final
> ByteVector dummyVector(...
> 
> 
> My personal opinion is that these should have been written like this:
> 
> 
> @Override
> @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override
> final ByteVector dummyVector(...
> 
> 
> or possibly
> 
> 
> 
> @Override @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline @Override
> final ByteVector dummyVector(...
> 
> 
> If you want me to make that change as well as part of the fix, let me know.
> 
> Furthermore, I don't know how much the code in mainline differs from the code 
> in the Panama branches. If the discrepancy is large, you might want to run 
> `bash bin/blessed-modifier-order.sh src/jdk.incubator.vector` and  `bash 
> bin/blessed-modifier-order.sh src/jdk.incubator.foreign` in those branches.

So the refresh is still upcoming? Sorry, I thought it was pushed last week. 
When it is pushed, I'll merge in master and the duplicated changes will just be 
removed from the PR.

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-17 Thread Maurizio Cimadamore
On Fri, 12 Nov 2021 17:01:38 GMT, Paul Sandoz  wrote:

>>> > You could also do this directly in the Panama repo branches. I'll 
>>> > volunteer to help, if you want.
>>> 
>>> I'll run the script on the PR I've submitted for the Foreign API, and I 
>>> will update that one - thanks. Perhaps @PaulSandoz can do the same for the 
>>> Vector API refresh?
>> 
>> Done - the jdk.incubator.foreign changes are now part of 
>> https://github.com/openjdk/jdk/pull/5907
>
>> @mcimadamore Thanks!
>> 
>> @PaulSandoz I'll keep this PR open until after the integration is done, and 
>> check if or what parts are still needed after that. I don't want to mess up 
>> your integration with trivia like this. (Had I realized the bad timing I 
>> would have waited before opening this PR)
> 
> Thanks, integration should happen to today, then i can help guide you on what 
> to update.

> @PaulSandoz @mcimadamore Would you be ok with me pushing this now?

As the foreign API bits have been made part of the upcoming foreign PR refresh, 
I think this patch should perhaps avoid changes inside jdk.incubator.foreign 
(to avoid potential conflicts).

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-17 Thread Magnus Ihse Bursie
On Fri, 12 Nov 2021 17:01:38 GMT, Paul Sandoz  wrote:

>>> > You could also do this directly in the Panama repo branches. I'll 
>>> > volunteer to help, if you want.
>>> 
>>> I'll run the script on the PR I've submitted for the Foreign API, and I 
>>> will update that one - thanks. Perhaps @PaulSandoz can do the same for the 
>>> Vector API refresh?
>> 
>> Done - the jdk.incubator.foreign changes are now part of 
>> https://github.com/openjdk/jdk/pull/5907
>
>> @mcimadamore Thanks!
>> 
>> @PaulSandoz I'll keep this PR open until after the integration is done, and 
>> check if or what parts are still needed after that. I don't want to mess up 
>> your integration with trivia like this. (Had I realized the bad timing I 
>> would have waited before opening this PR)
> 
> Thanks, integration should happen to today, then i can help guide you on what 
> to update.

@PaulSandoz @mcimadamore Would you be ok with me pushing this now?

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-12 Thread Paul Sandoz
On Fri, 12 Nov 2021 11:13:24 GMT, Maurizio Cimadamore  
wrote:

>>> You could also do this directly in the Panama repo branches. I'll volunteer 
>>> to help, if you want.
>> 
>> I'll run the script on the PR I've submitted for the Foreign API, and I will 
>> update that one - thanks. Perhaps @PaulSandoz can do the same for the Vector 
>> API refresh?
>
>> > You could also do this directly in the Panama repo branches. I'll 
>> > volunteer to help, if you want.
>> 
>> I'll run the script on the PR I've submitted for the Foreign API, and I will 
>> update that one - thanks. Perhaps @PaulSandoz can do the same for the Vector 
>> API refresh?
> 
> Done - the jdk.incubator.foreign changes are now part of 
> https://github.com/openjdk/jdk/pull/5907

> @mcimadamore Thanks!
> 
> @PaulSandoz I'll keep this PR open until after the integration is done, and 
> check if or what parts are still needed after that. I don't want to mess up 
> your integration with trivia like this. (Had I realized the bad timing I 
> would have waited before opening this PR)

Thanks, integration should happen to today, then i can help guide you on what 
to update.

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-12 Thread Magnus Ihse Bursie
On Fri, 12 Nov 2021 11:13:24 GMT, Maurizio Cimadamore  
wrote:

>>> You could also do this directly in the Panama repo branches. I'll volunteer 
>>> to help, if you want.
>> 
>> I'll run the script on the PR I've submitted for the Foreign API, and I will 
>> update that one - thanks. Perhaps @PaulSandoz can do the same for the Vector 
>> API refresh?
>
>> > You could also do this directly in the Panama repo branches. I'll 
>> > volunteer to help, if you want.
>> 
>> I'll run the script on the PR I've submitted for the Foreign API, and I will 
>> update that one - thanks. Perhaps @PaulSandoz can do the same for the Vector 
>> API refresh?
> 
> Done - the jdk.incubator.foreign changes are now part of 
> https://github.com/openjdk/jdk/pull/5907

@mcimadamore Thanks!

@PaulSandoz I'll keep this PR open until after the integration is done, and 
check if or what parts are still needed after that. I don't want to mess up 
your integration with trivia like this. (Had I realized the bad timing I would 
have waited before opening this PR)

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-12 Thread Maurizio Cimadamore
On Thu, 11 Nov 2021 21:34:17 GMT, Maurizio Cimadamore  
wrote:

> > You could also do this directly in the Panama repo branches. I'll volunteer 
> > to help, if you want.
> 
> I'll run the script on the PR I've submitted for the Foreign API, and I will 
> update that one - thanks. Perhaps @PaulSandoz can do the same for the Vector 
> API refresh?

Done - the jdk.incubator.foreign changes are now part of 
https://github.com/openjdk/jdk/pull/5907

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Paul Sandoz
On Thu, 11 Nov 2021 15:47:11 GMT, Maurizio Cimadamore  
wrote:

>> I ran bin/blessed-modifier-order.sh on source owned by Project Panama. This 
>> scripts verifies that modifiers are in the "blessed" order, and fixes it 
>> otherwise. I have manually checked the changes made by the script to make 
>> sure they are sound.
>> 
>> In this case, while the script did into the "correct" thing, it turns out 
>> that the method signatures in 
>> `src/jdk.incubator.vector/share/classes/jdk/incubator/vector` has some room 
>> for improvement... The files contains method headers which look like this:
>> 
>> 
>> final @Override
>> @ForceInline
>> long longToElementBits(...
>> 
>> @ForceInline
>> static long toIntegralChecked(...
>> 
>> @ForceInline
>> @Override final
>> ByteVector dummyVector(...
>> 
>> 
>> My personal opinion is that these should have been written like this:
>> 
>> 
>> @Override
>> @ForceInline
>> final long longToElementBits(...
>> 
>> @ForceInline
>> static long toIntegralChecked(...
>> 
>> @ForceInline
>> @Override
>> final ByteVector dummyVector(...
>> 
>> 
>> or possibly
>> 
>> 
>> 
>> @Override @ForceInline
>> final long longToElementBits(...
>> 
>> @ForceInline
>> static long toIntegralChecked(...
>> 
>> @ForceInline @Override
>> final ByteVector dummyVector(...
>> 
>> 
>> If you want me to make that change as well as part of the fix, let me know.
>> 
>> Furthermore, I don't know how much the code in mainline differs from the 
>> code in the Panama branches. If the discrepancy is large, you might want to 
>> run `bash bin/blessed-modifier-order.sh src/jdk.incubator.vector` and  `bash 
>> bin/blessed-modifier-order.sh src/jdk.incubator.foreign` in those branches.
>
> src/jdk.incubator.vector/share/classes/jdk/incubator/vector/ByteVector.java 
> line 3908:
> 
>> 3906: 
>> 3907: @ForceInline
>> 3908: @Override public
> 
> `public` should probably go on a different line? (same as for the ones that 
> follow)

Note these files are generated from a template `X-Vector.java.template` and the 
script `gen-src.sh` (not yet integrated into the build system). So the template 
requires updating, from which the script is run to generate the source. We can 
do this after integration of https://github.com/openjdk/jdk/pull/5873/

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Paul Sandoz
On Thu, 11 Nov 2021 14:50:43 GMT, Magnus Ihse Bursie  wrote:

> I ran bin/blessed-modifier-order.sh on source owned by Project Panama. This 
> scripts verifies that modifiers are in the "blessed" order, and fixes it 
> otherwise. I have manually checked the changes made by the script to make 
> sure they are sound.
> 
> In this case, while the script did into the "correct" thing, it turns out 
> that the method signatures in 
> `src/jdk.incubator.vector/share/classes/jdk/incubator/vector` has some room 
> for improvement... The files contains method headers which look like this:
> 
> 
> final @Override
> @ForceInline
> long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override final
> ByteVector dummyVector(...
> 
> 
> My personal opinion is that these should have been written like this:
> 
> 
> @Override
> @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override
> final ByteVector dummyVector(...
> 
> 
> or possibly
> 
> 
> 
> @Override @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline @Override
> final ByteVector dummyVector(...
> 
> 
> If you want me to make that change as well as part of the fix, let me know.
> 
> Furthermore, I don't know how much the code in mainline differs from the code 
> in the Panama branches. If the discrepancy is large, you might want to run 
> `bash bin/blessed-modifier-order.sh src/jdk.incubator.vector` and  `bash 
> bin/blessed-modifier-order.sh src/jdk.incubator.foreign` in those branches.

I would prefer to leave the Vector API PR as is, we are getting close to 
integration, and apply such changes after integration as a separate commit on 
the mainline.

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Maurizio Cimadamore
On Thu, 11 Nov 2021 20:22:25 GMT, Magnus Ihse Bursie  wrote:

> You could also do this directly in the Panama repo branches. I'll volunteer 
> to help, if you want.

I'll run the script on the PR I've submitted for the Foreign API, and I will 
update that one - thanks. Perhaps @PaulSandoz can do the same for the Vector 
API refresh?

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Magnus Ihse Bursie
On Thu, 11 Nov 2021 14:50:43 GMT, Magnus Ihse Bursie  wrote:

> I ran bin/blessed-modifier-order.sh on source owned by Project Panama. This 
> scripts verifies that modifiers are in the "blessed" order, and fixes it 
> otherwise. I have manually checked the changes made by the script to make 
> sure they are sound.
> 
> In this case, while the script did into the "correct" thing, it turns out 
> that the method signatures in 
> `src/jdk.incubator.vector/share/classes/jdk/incubator/vector` has some room 
> for improvement... The files contains method headers which look like this:
> 
> 
> final @Override
> @ForceInline
> long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override final
> ByteVector dummyVector(...
> 
> 
> My personal opinion is that these should have been written like this:
> 
> 
> @Override
> @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override
> final ByteVector dummyVector(...
> 
> 
> or possibly
> 
> 
> 
> @Override @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline @Override
> final ByteVector dummyVector(...
> 
> 
> If you want me to make that change as well as part of the fix, let me know.
> 
> Furthermore, I don't know how much the code in mainline differs from the code 
> in the Panama branches. If the discrepancy is large, you might want to run 
> `bash bin/blessed-modifier-order.sh src/jdk.incubator.vector` and  `bash 
> bin/blessed-modifier-order.sh src/jdk.incubator.foreign` in those branches.

You could also do this directly in the Panama repo branches. I'll volunteer to 
help, if you want.

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Maurizio Cimadamore
On Thu, 11 Nov 2021 15:58:06 GMT, Magnus Ihse Bursie  wrote:

> This is by no means urgent. If it's more convenient for you to wait until 
> after the refresh, I can certainly do so.

I guess there is a chance that after vector and foreign are re-incubated in 18, 
we might need to do this again.

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Magnus Ihse Bursie
On Thu, 11 Nov 2021 14:50:43 GMT, Magnus Ihse Bursie  wrote:

> I ran bin/blessed-modifier-order.sh on source owned by Project Panama. This 
> scripts verifies that modifiers are in the "blessed" order, and fixes it 
> otherwise. I have manually checked the changes made by the script to make 
> sure they are sound.
> 
> In this case, while the script did into the "correct" thing, it turns out 
> that the method signatures in 
> `src/jdk.incubator.vector/share/classes/jdk/incubator/vector` has some room 
> for improvement... The files contains method headers which look like this:
> 
> 
> final @Override
> @ForceInline
> long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override final
> ByteVector dummyVector(...
> 
> 
> My personal opinion is that these should have been written like this:
> 
> 
> @Override
> @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override
> final ByteVector dummyVector(...
> 
> 
> or possibly
> 
> 
> 
> @Override @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline @Override
> final ByteVector dummyVector(...
> 
> 
> If you want me to make that change as well as part of the fix, let me know.
> 
> Furthermore, I don't know how much the code in mainline differs from the code 
> in the Panama branches. If the discrepancy is large, you might want to run 
> `bash bin/blessed-modifier-order.sh src/jdk.incubator.vector` and  `bash 
> bin/blessed-modifier-order.sh src/jdk.incubator.foreign` in those branches.

This is by no means urgent. If it's more convenient for you to wait until after 
the refresh, I can certainly do so.

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Maurizio Cimadamore
On Thu, 11 Nov 2021 14:50:43 GMT, Magnus Ihse Bursie  wrote:

> I ran bin/blessed-modifier-order.sh on source owned by Project Panama. This 
> scripts verifies that modifiers are in the "blessed" order, and fixes it 
> otherwise. I have manually checked the changes made by the script to make 
> sure they are sound.
> 
> In this case, while the script did into the "correct" thing, it turns out 
> that the method signatures in 
> `src/jdk.incubator.vector/share/classes/jdk/incubator/vector` has some room 
> for improvement... The files contains method headers which look like this:
> 
> 
> final @Override
> @ForceInline
> long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override final
> ByteVector dummyVector(...
> 
> 
> My personal opinion is that these should have been written like this:
> 
> 
> @Override
> @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline
> @Override
> final ByteVector dummyVector(...
> 
> 
> or possibly
> 
> 
> 
> @Override @ForceInline
> final long longToElementBits(...
> 
> @ForceInline
> static long toIntegralChecked(...
> 
> @ForceInline @Override
> final ByteVector dummyVector(...
> 
> 
> If you want me to make that change as well as part of the fix, let me know.
> 
> Furthermore, I don't know how much the code in mainline differs from the code 
> in the Panama branches. If the discrepancy is large, you might want to run 
> `bash bin/blessed-modifier-order.sh src/jdk.incubator.vector` and  `bash 
> bin/blessed-modifier-order.sh src/jdk.incubator.foreign` in those branches.

On a  second look, changes are relatively contained. I'm ok with integrating 
this ahead of the Panama/foreign refresh. I found a possible issue in the 
vector API, with `public` being of the same line as the annotation, which looks 
odd (as you have noticed).

src/jdk.incubator.vector/share/classes/jdk/incubator/vector/ByteVector.java 
line 3908:

> 3906: 
> 3907: @ForceInline
> 3908: @Override public

`public` should probably go on a different line? (same as for the ones that 
follow)

-

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Maurizio Cimadamore

Hi Magnus,
as we're in the process of integrating new API changes (see [1]) - would 
it be possible to postpone this? I'd like to minimize merge conflicts, 
if that makes sense.


Thanks
Maurizio

[1] - https://github.com/openjdk/jdk/pull/5907

On 11/11/2021 14:57, Magnus Ihse Bursie wrote:

I ran bin/blessed-modifier-order.sh on source owned by Project Panama. This scripts 
verifies that modifiers are in the "blessed" order, and fixes it otherwise. I 
have manually checked the changes made by the script to make sure they are sound.

In this case, while the script did into the "correct" thing, it turns out that 
the method signatures in `src/jdk.incubator.vector/share/classes/jdk/incubator/vector` 
has some room for improvement... The files contains method headers which look like this:


 final @Override
 @ForceInline
 long longToElementBits(...

 @ForceInline
 static long toIntegralChecked(...

 @ForceInline
 @Override final
 ByteVector dummyVector(...


My personal opinion is that these should have been written like this:


 @Override
 @ForceInline
 final long longToElementBits(...

 @ForceInline
 static long toIntegralChecked(...

 @ForceInline
 @Override
 final ByteVector dummyVector(...


or possibly



 @Override @ForceInline
 final long longToElementBits(...

 @ForceInline
 static long toIntegralChecked(...

 @ForceInline @Override
 final ByteVector dummyVector(...


If you want me to make that change as well as part of the fix, let me know.

Furthermore, I don't know how much the code in mainline differs from the code 
in the Panama branches. If the discrepancy is large, you might want to run 
`bash bin/blessed-modifier-order.sh src/jdk.incubator.vector` and  `bash 
bin/blessed-modifier-order.sh src/jdk.incubator.foreign` in those branches.

-

Commit messages:
  - 8277015: Use blessed modifier order in Panama code

Changes: https://git.openjdk.java.net/jdk/pull/6355/files
  Webrev: https://webrevs.openjdk.java.net/?repo=jdk=6355=00
   Issue: https://bugs.openjdk.java.net/browse/JDK-8277015
   Stats: 21 lines in 13 files changed: 0 ins; 0 del; 21 mod
   Patch: https://git.openjdk.java.net/jdk/pull/6355.diff
   Fetch: git fetch https://git.openjdk.java.net/jdk pull/6355/head:pull/6355

PR: https://git.openjdk.java.net/jdk/pull/6355


Re: RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Magnus Ihse Bursie
I assume this is relevant for panama-dev as well, but I can't 
unfortunately tag the issue as such in Github/Skara. (Maybe we should 
have a mapping for jdk.incubator.vector/foreign -> panama-dev?)


/Magnus

On 2021-11-11 15:57, Magnus Ihse Bursie wrote:

I ran bin/blessed-modifier-order.sh on source owned by Project Panama. This scripts 
verifies that modifiers are in the "blessed" order, and fixes it otherwise. I 
have manually checked the changes made by the script to make sure they are sound.

In this case, while the script did into the "correct" thing, it turns out that 
the method signatures in `src/jdk.incubator.vector/share/classes/jdk/incubator/vector` 
has some room for improvement... The files contains method headers which look like this:


 final @Override
 @ForceInline
 long longToElementBits(...

 @ForceInline
 static long toIntegralChecked(...

 @ForceInline
 @Override final
 ByteVector dummyVector(...


My personal opinion is that these should have been written like this:


 @Override
 @ForceInline
 final long longToElementBits(...

 @ForceInline
 static long toIntegralChecked(...

 @ForceInline
 @Override
 final ByteVector dummyVector(...


or possibly



 @Override @ForceInline
 final long longToElementBits(...

 @ForceInline
 static long toIntegralChecked(...

 @ForceInline @Override
 final ByteVector dummyVector(...


If you want me to make that change as well as part of the fix, let me know.

Furthermore, I don't know how much the code in mainline differs from the code 
in the Panama branches. If the discrepancy is large, you might want to run 
`bash bin/blessed-modifier-order.sh src/jdk.incubator.vector` and  `bash 
bin/blessed-modifier-order.sh src/jdk.incubator.foreign` in those branches.

-

Commit messages:
  - 8277015: Use blessed modifier order in Panama code

Changes: https://git.openjdk.java.net/jdk/pull/6355/files
  Webrev: https://webrevs.openjdk.java.net/?repo=jdk=6355=00
   Issue: https://bugs.openjdk.java.net/browse/JDK-8277015
   Stats: 21 lines in 13 files changed: 0 ins; 0 del; 21 mod
   Patch: https://git.openjdk.java.net/jdk/pull/6355.diff
   Fetch: git fetch https://git.openjdk.java.net/jdk pull/6355/head:pull/6355

PR: https://git.openjdk.java.net/jdk/pull/6355




RFR: 8277015: Use blessed modifier order in Panama code

2021-11-11 Thread Magnus Ihse Bursie
I ran bin/blessed-modifier-order.sh on source owned by Project Panama. This 
scripts verifies that modifiers are in the "blessed" order, and fixes it 
otherwise. I have manually checked the changes made by the script to make sure 
they are sound.

In this case, while the script did into the "correct" thing, it turns out that 
the method signatures in 
`src/jdk.incubator.vector/share/classes/jdk/incubator/vector` has some room for 
improvement... The files contains method headers which look like this:


final @Override
@ForceInline
long longToElementBits(...

@ForceInline
static long toIntegralChecked(...

@ForceInline
@Override final
ByteVector dummyVector(...


My personal opinion is that these should have been written like this:


@Override
@ForceInline
final long longToElementBits(...

@ForceInline
static long toIntegralChecked(...

@ForceInline
@Override
final ByteVector dummyVector(...


or possibly



@Override @ForceInline
final long longToElementBits(...

@ForceInline
static long toIntegralChecked(...

@ForceInline @Override
final ByteVector dummyVector(...


If you want me to make that change as well as part of the fix, let me know.

Furthermore, I don't know how much the code in mainline differs from the code 
in the Panama branches. If the discrepancy is large, you might want to run 
`bash bin/blessed-modifier-order.sh src/jdk.incubator.vector` and  `bash 
bin/blessed-modifier-order.sh src/jdk.incubator.foreign` in those branches.

-

Commit messages:
 - 8277015: Use blessed modifier order in Panama code

Changes: https://git.openjdk.java.net/jdk/pull/6355/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk=6355=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8277015
  Stats: 21 lines in 13 files changed: 0 ins; 0 del; 21 mod
  Patch: https://git.openjdk.java.net/jdk/pull/6355.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/6355/head:pull/6355

PR: https://git.openjdk.java.net/jdk/pull/6355