The original title of this CR was "Redundant Math.ceil call in ELFFileParser" and had the description below, but it has since been determined that ELFFileParser is no longer used and should just be removed, thus the title change:
---------------------------------
There are couple of places in the method 'sun.jvm.hotspot.debugger.posix.elf.ELFFileParser.ELFFileImpl.ELFHeaderImpl#getELFSymbol' where `Math.ceil` called with 'int' arguments. Calling Math.ceil with integer argument is useless - it will just return the same passed value.
https://github.com/openjdk/jdk/blob/156f0b4332bf076165898417cf6678d2fc32df5c/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/debugger/posix/elf/ELFFileParser.java#L307
https://github.com/openjdk/jdk/blob/156f0b4332bf076165898417cf6678d2fc32df5c/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/debugger/posix/elf/ELFFileParser.java#L323
for (int i = 0; i < Math.ceil(numSymbols / 2); i++) {
'numSymbols' is 'int'.
Seems we should remove them.
---------------------------------
There are couple of places in the method 'sun.jvm.hotspot.debugger.posix.elf.ELFFileParser.ELFFileImpl.ELFHeaderImpl#getELFSymbol' where `Math.ceil` called with 'int' arguments. Calling Math.ceil with integer argument is useless - it will just return the same passed value.
https://github.com/openjdk/jdk/blob/156f0b4332bf076165898417cf6678d2fc32df5c/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/debugger/posix/elf/ELFFileParser.java#L307
https://github.com/openjdk/jdk/blob/156f0b4332bf076165898417cf6678d2fc32df5c/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/debugger/posix/elf/ELFFileParser.java#L323
for (int i = 0; i < Math.ceil(numSymbols / 2); i++) {
'numSymbols' is 'int'.
Seems we should remove them.