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:
Christian Thalinger 2010-01-05 15:21:25 +01:00
parent 375527d84e
commit 47f2433a58
52 changed files with 1781 additions and 342 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright 1999-2007 Sun Microsystems, Inc. All Rights Reserved.
* Copyright 1999-2009 Sun Microsystems, Inc. All Rights Reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -59,6 +59,22 @@ int ciSymbol::byte_at(int i) {
GUARDED_VM_ENTRY(return get_symbolOop()->byte_at(i);)
}
// ------------------------------------------------------------------
// ciSymbol::starts_with
//
// Tests if the symbol starts with the given prefix.
bool ciSymbol::starts_with(const char* prefix, int len) const {
GUARDED_VM_ENTRY(return get_symbolOop()->starts_with(prefix, len);)
}
// ------------------------------------------------------------------
// ciSymbol::index_of
//
// Determines where the symbol contains the given substring.
int ciSymbol::index_of_at(int i, const char* str, int len) const {
GUARDED_VM_ENTRY(return get_symbolOop()->index_of_at(i, str, len);)
}
// ------------------------------------------------------------------
// ciSymbol::utf8_length
int ciSymbol::utf8_length() {