RFR(s): 8151264: Add a notification mechanism for UL configuration changes
David Holmes
david.holmes at oracle.com
Thu Mar 10 10:19:28 UTC 2016
Hi Robbin,
On 9/03/2016 7:02 PM, Robbin Ehn wrote:
>
> Hi, please review this minor change.
A notification mechanism is not so minor - what are the programming
rules for the callbacks? which threads might execute them? Are there any
obvious deadlock/livelock potentials? Do we need to unregister a callback?
At a minimum there should be some comments regarding the nature of the
callback and what it can and can't do.
> Bug: https://bugs.openjdk.java.net/browse/JDK-8151264/
> Webrev: http://cr.openjdk.java.net/~rehn/8151264/webrev/
Some minor nits:
src/share/vm/logging/log.cpp
Copyright needs 2016 added.
---
src/share/vm/logging/logConfiguration.cpp
+ assert(cb != NULL, "Should not initialize register NULL as listener.");
"initialize register" doesn't make grammatical sense - delete "initialize"
+ for (size_t i=0;i<_n_listener_callbacks;i++) {
Style nits: spaces around operators and after ;
---
src/share/vm/logging/logConfiguration.hpp
+ // After any configuration change this method should be called by in
scope of LogConfigurationLock
Delete 'by' - or may I suggest:
// This should be called after any configuration change while still
holding ConfigurationLock
Thanks,
David
-----
> Tested with a new internal vm test (included).
>
> Thanks!
>
> /Robbin
More information about the hotspot-runtime-dev
mailing list