RFR (XL): 7172640: C2: instrinsic implementations in LibraryCallKit should use argument() instead of pop()

Christian Thalinger christian.thalinger at oracle.com
Tue Nov 20 18:47:03 PST 2012


http://cr.openjdk.java.net/~twisti/7172640

7172640: C2: instrinsic implementations in LibraryCallKit should use argument() instead of pop()
Reviewed-by:

Most intrinsics in LibraryCallKit re-push the arguments that have been
popped off before the call to just pop them again as arguments.  It
would be much cleaner and more correct to use argument() accessors
instead.

Another problem is that it is very tricky to find the places where the
stack pointer needs to be adjusted to the correct value for
re-execution (uncommon traps).  This adjustment is a plain SP bump and
decrease after the call.  In itself very error prone and it could be
handled in a much more elegant way.

src/share/vm/ci/ciMethod.cpp
src/share/vm/ci/ciMethod.hpp
src/share/vm/ci/ciSignature.hpp
src/share/vm/interpreter/bytecodes.hpp
src/share/vm/opto/callGenerator.cpp
src/share/vm/opto/callnode.hpp
src/share/vm/opto/doCall.cpp
src/share/vm/opto/graphKit.cpp
src/share/vm/opto/graphKit.hpp
src/share/vm/opto/library_call.cpp
src/share/vm/opto/parse1.cpp
src/share/vm/opto/parse2.cpp
src/share/vm/opto/parse3.cpp
src/share/vm/opto/parseHelper.cpp
src/share/vm/opto/type.hpp



More information about the hotspot-compiler-dev mailing list