RFR(M/T) : 8243935 : s.h.WhiteBoxPermission must be ClassFileInstall-ed together w/ s.h.WhiteBox

Stefan Karlsson stefan.karlsson at oracle.com
Tue Apr 28 07:34:54 UTC 2020


Hi,

I have another idea. Can't we simply remove WhiteBoxPermission and 
incorporate that functionality in the WhiteBox class? We would then be 
able to remove all these WhiteBoxPermission lines.

I've tested this and it seems to work:
https://cr.openjdk.java.net/~stefank/prototype/removeWhiteBoxPermission/webrev.01/

Summary of changes:    695 lines changed: 0 ins; 657 del; 38 mod; 60752 
unchg

The interesting code:
https://cr.openjdk.java.net/~stefank/prototype/removeWhiteBoxPermission/webrev.01/test/lib/sun/hotspot/WhiteBox.java.udiff.html

(There are some parts of the patch that was butchered by the sed-script 
- I'll fix this if we agree that this is a good thing to do)

If you think this is something we should do, I'll create an RFE, 
complete the patch, run more tests, and send it out for review.

Thanks,
StefanK

On 2020-04-28 08:08, David Holmes wrote:
> On 28/04/2020 3:37 pm, Igor Ignatyev wrote:
>>
>>
>>> On Apr 27, 2020, at 10:03 PM, David Holmes <david.holmes at oracle.com> 
>>> wrote:
>>>
>>> Hi Igor,
>>>
>>> On 28/04/2020 12:32 pm, Igor Ignatyev wrote:
>>>> http://cr.openjdk.java.net/~iignatyev//8243935/webrev.00/
>>>>> 338 lines changed: 107 ins; 0 del; 231 mod
>>>> Hi all,
>>>> could you please review the trivial yet tedious patch which adds 
>>>> 'sun.hotspot.WhiteBox$WhiteBoxPermission' to all 
>>>> 'ClassFileInstaller sun.hotspot.WhiteBox' actions?
>>>> the patch also
>>>>   - replaces '@run main ClassFileInstaller' w/ '@run driver 
>>>> ClassFileInstaller'
>>>>   - unifies the way ClassFileInstaller sun.hotspot.WhiteBox are 
>>>> aligned
>>>
>>> That alignment change is unnecessary and makes it very hard to 
>>> review this patch.
>>>
>>>> JBS: https://bugs.openjdk.java.net/browse/JDK-8243935
>>>> webrevs:
>>>>   - http://cr.openjdk.java.net/~iignatyev//8243935/webrev.00/ -- 
>>>> regular webrev
>>>>   - 
>>>> http://cr.openjdk.java.net/~iignatyev//8243935/webrev.00.including_ws 
>>>> -- shows "whitespace only" changes
>>>
>>> I'd like to see the patch that leaves out the whitespace-only 
>>> changes - is that possible?
>> sure, I've used `hg diff -w` (--ignore-all-space    ignore white 
>> space when comparing lines) to remove all whitespace changes, here is 
>> webrev -- http://cr.openjdk.java.net/~iignatyev//8243935/webrev.00.w/
>
> Thanks that was somewhat better. Change seems okay.
>
> David
>
>> -- Igor
>>>
>>> Thanks,
>>> David
>>>
>>>> Thanks,
>>>> -- Igor
>>



More information about the hotspot-dev mailing list