mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-21 19:44:41 +02:00
6893268: additional dynamic language related optimizations in C2
C2 needs some additional optimizations to be able to handle MethodHandle invokes and invokedynamic instructions at the best performance. Reviewed-by: kvn, never
This commit is contained in:
parent
375527d84e
commit
47f2433a58
52 changed files with 1781 additions and 342 deletions
|
@ -247,15 +247,22 @@ methodHandle Rewriter::rewrite_jsrs(methodHandle method, TRAPS) {
|
|||
|
||||
void Rewriter::rewrite(instanceKlassHandle klass, TRAPS) {
|
||||
ResourceMark rm(THREAD);
|
||||
Rewriter rw(klass, CHECK);
|
||||
Rewriter rw(klass, klass->constants(), klass->methods(), CHECK);
|
||||
// (That's all, folks.)
|
||||
}
|
||||
|
||||
Rewriter::Rewriter(instanceKlassHandle klass, TRAPS)
|
||||
|
||||
void Rewriter::rewrite(instanceKlassHandle klass, constantPoolHandle cpool, objArrayHandle methods, TRAPS) {
|
||||
ResourceMark rm(THREAD);
|
||||
Rewriter rw(klass, cpool, methods, CHECK);
|
||||
// (That's all, folks.)
|
||||
}
|
||||
|
||||
|
||||
Rewriter::Rewriter(instanceKlassHandle klass, constantPoolHandle cpool, objArrayHandle methods, TRAPS)
|
||||
: _klass(klass),
|
||||
// gather starting points
|
||||
_pool( THREAD, klass->constants()),
|
||||
_methods(THREAD, klass->methods())
|
||||
_pool(cpool),
|
||||
_methods(methods)
|
||||
{
|
||||
assert(_pool->cache() == NULL, "constant pool cache must not be set yet");
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue