mirror of
https://github.com/openjdk/jdk.git
synced 2026-04-20 11:50:25 +00:00
8065985: Inlining failure of Number.doubleValue() in JSType.toNumeric() causes 15% peak perf regresion on Box2D
Reviewed-by: lagergren, hannesw
This commit is contained in:
parent
e79371a0bc
commit
a0485e336d
@ -714,6 +714,9 @@ public enum JSType {
|
||||
* @return a number
|
||||
*/
|
||||
public static double toNumber(final Object obj) {
|
||||
if (obj instanceof Double) {
|
||||
return (Double)obj;
|
||||
}
|
||||
if (obj instanceof Number) {
|
||||
return ((Number)obj).doubleValue();
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user