Skip to content

Commit 7c169a4

Browse files
committedAug 22, 2023
8312232: Remove sun.jvm.hotspot.runtime.VM.buildLongFromIntsPD()
Reviewed-by: lmesnik, kevinw
1 parent 2eae13c commit 7c169a4

File tree

2 files changed

+2
-15
lines changed

2 files changed

+2
-15
lines changed
 

‎src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/StackValueCollection.java

+1-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2001, 2022, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2001, 2023, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -47,8 +47,6 @@ public class StackValueCollection {
4747
public char charAt(int slot) { return (char) get(slot).getInteger(); }
4848
public short shortAt(int slot) { return (short) get(slot).getInteger(); }
4949
public int intAt(int slot) { return (int) get(slot).getInteger(); }
50-
public long longAt(int slot) { return VM.getVM().buildLongFromIntsPD((int) get(slot).getInteger(),
51-
(int) get(slot+1).getInteger()); }
5250

5351
public OopHandle oopHandleAt(int slot) {
5452
StackValue sv = get(slot);
@@ -59,5 +57,4 @@ public OopHandle oopHandleAt(int slot) {
5957
}
6058

6159
public float floatAt(int slot) { return Float.intBitsToFloat(intAt(slot)); }
62-
public double doubleAt(int slot) { return Double.longBitsToDouble(longAt(slot)); }
6360
}

‎src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/runtime/VM.java

+1-11
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2000, 2022, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2000, 2023, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -727,16 +727,6 @@ public int buildIntFromShorts(short low, short high) {
727727
return (((int) high) << 16) | (((int) low) & 0xFFFF);
728728
}
729729

730-
/** Utility routine for building a long from two "unsigned" 32-bit
731-
ints in <b>platform-dependent</b> order */
732-
public long buildLongFromIntsPD(int oneHalf, int otherHalf) {
733-
if (isBigEndian) {
734-
return (((long) otherHalf) << 32) | (((long) oneHalf) & 0x00000000FFFFFFFFL);
735-
} else{
736-
return (((long) oneHalf) << 32) | (((long) otherHalf) & 0x00000000FFFFFFFFL);
737-
}
738-
}
739-
740730
public TypeDataBase getTypeDataBase() {
741731
return db;
742732
}

0 commit comments

Comments
 (0)
Please sign in to comment.