On 05/26/2011 09:10 PM, Y. S. Ramakrishna wrote: > John, you state that validity is not a stable property. > Is invalidity a stable property, or not even that is.
yes, once invalidated a switch point can't be reverted to a valid state. http://download.java.net/jdk7/docs/api/java/lang/invoke/SwitchPoint.html > -- ramki > (who doesn't yet know what a switchpoint is) Rémi > On 05/26/11 10:11, Tom Rodriguez wrote: >> isValid looks fine. >> >> tom >> >> On May 26, 2011, at 1:31 AM, John Rose wrote: >> >>> On May 25, 2011, at 11:58 PM, Tom Rodriguez wrote: >>> >>>> Overall it seems ok. A few minor oddities: >>>> >>>> MethodHandle.java >>>> >>>> variable arity is sometimes hyphenated. It seems more correct without but >>>> be consistent. >>> Replaced hyphen by space. >>> >>>> AdapterMethodHandle.java: >>>> >>>> The new value srcSlot appears unused. >>> Right; it doesn't have any use. Deleted. >>> >>>> Should this just go away: >>>> >>>> - if (argCount<= 2) return false; // must be a swap, not a rotate >>>> + //if (argCount<= 2) return false; // must be a swap, not a >>>> rotate >>> Yes. Turns out that if you need to swap an int and a long, it has to be >>> rendered as one or two rotates. >>> >>> Thanks, Tom. >>> >>> -- John >>> >>> P.S. One more bit to review: I might add the following to >>> SwitchPoint.java, depending on what the EG says today. >>> >>> /** >>> * Determines if this switchpoint is still valid. >>> *<p> >>> * Since invalidation is a global and immediate operation, >>> * this query must be sequenced with any >>> * other threads that could invalidate this switchpoint. >>> * It may therefore be expensive. >>> *<p> >>> * In addition, due to concurrent invalidations by other threads, >>> * a switchpoint may report itself as valid, and yet become >>> * invalid before the querying thread begins to act on the >>> * supposed validity. >>> * @return true if this switchpoint has never been invalidated >>> */ >>> public boolean isValid() { >>> return (mcs.getTarget() == K_true); >>> } >>> >>>> tom >>>> >>>> On May 25, 2011, at 3:30 AM, John Rose wrote: >>>> >>>>> This is the last major bundle of changes for JDK 7. >>>>> http://cr.openjdk.java.net/~jrose/7032323/webrev.00/ > _______________________________________________ > mlvm-dev mailing list > [email protected] > http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev _______________________________________________ mlvm-dev mailing list [email protected] http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev
