RFR: 8343837: Remove unnecessary reinterpret_cast from C2AccessValuePtr [v2]
theoweidmannoracle
duke at openjdk.org
Fri Nov 8 13:45:34 UTC 2024
> C2AccessValuePtr contains a reinterpret cast from TypePtr* to its base class Type*. This cast was added in [JDK-8202377](https://bugs.openjdk.org/browse/JDK-8202377), due to a circular dependency problem, which no longer exists. The code compiles fine without it and this cast was removed.
>
> Furthermore, a downcast from Type* to TypePtr* exists in this class using reinterpret_cast. This is replaced with the less powerful and more safe static_cast.
theoweidmannoracle has updated the pull request incrementally with one additional commit since the last revision:
Update src/hotspot/share/gc/shared/c2/barrierSetC2.hpp
Co-authored-by: Tobias Hartmann <tobias.hartmann at oracle.com>
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/21977/files
- new: https://git.openjdk.org/jdk/pull/21977/files/f5251e38..dfe4d65e
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=21977&range=01
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=21977&range=00-01
Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod
Patch: https://git.openjdk.org/jdk/pull/21977.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/21977/head:pull/21977
PR: https://git.openjdk.org/jdk/pull/21977
More information about the hotspot-dev
mailing list