mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-21 19:44:41 +02:00
6912063: inlining parameters need to be adjusted for some uses of the JVM
Put all inline-related switches into product mode, to allow tuning by dynamic language implementors. Reviewed-by: twisti, kvn
This commit is contained in:
parent
fdbb64ef71
commit
6fbdf208fc
4 changed files with 58 additions and 19 deletions
|
@ -39,6 +39,7 @@ class InlineTree : public ResourceObj {
|
|||
// Always between 0.0 and 1.0. Represents the percentage of the method's
|
||||
// total execution time used at this call site.
|
||||
const float _site_invoke_ratio;
|
||||
const int _site_depth_adjust;
|
||||
float compute_callee_frequency( int caller_bci ) const;
|
||||
|
||||
GrowableArray<InlineTree*> _subtrees;
|
||||
|
@ -50,7 +51,8 @@ protected:
|
|||
ciMethod* callee_method,
|
||||
JVMState* caller_jvms,
|
||||
int caller_bci,
|
||||
float site_invoke_ratio);
|
||||
float site_invoke_ratio,
|
||||
int site_depth_adjust);
|
||||
InlineTree *build_inline_tree_for_callee(ciMethod* callee_method,
|
||||
JVMState* caller_jvms,
|
||||
int caller_bci);
|
||||
|
@ -61,14 +63,15 @@ protected:
|
|||
|
||||
InlineTree *caller_tree() const { return _caller_tree; }
|
||||
InlineTree* callee_at(int bci, ciMethod* m) const;
|
||||
int inline_depth() const { return _caller_jvms ? _caller_jvms->depth() : 0; }
|
||||
int inline_depth() const { return stack_depth() + _site_depth_adjust; }
|
||||
int stack_depth() const { return _caller_jvms ? _caller_jvms->depth() : 0; }
|
||||
|
||||
public:
|
||||
static InlineTree* build_inline_tree_root();
|
||||
static InlineTree* find_subtree_from_root(InlineTree* root, JVMState* jvms, ciMethod* callee, bool create_if_not_found = false);
|
||||
|
||||
// For temporary (stack-allocated, stateless) ilts:
|
||||
InlineTree(Compile* c, ciMethod* callee_method, JVMState* caller_jvms, float site_invoke_ratio);
|
||||
InlineTree(Compile* c, ciMethod* callee_method, JVMState* caller_jvms, float site_invoke_ratio, int site_depth_adjust);
|
||||
|
||||
// InlineTree enum
|
||||
enum InlineStyle {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue