Mercurial > hg > graal-jvmci-8
diff src/share/vm/opto/parse.hpp @ 1157:c3b315a0d58a
6912063: inlining parameters need to be adjusted for some uses of the JVM
Summary: Put all inline-related switches into product mode, to allow tuning by dynamic language implementors.
Reviewed-by: twisti, kvn
author | jrose |
---|---|
date | Fri, 08 Jan 2010 13:58:49 -0800 |
parents | 148e5441d916 |
children | b2b6a9bf6238 |
line wrap: on
line diff
--- a/src/share/vm/opto/parse.hpp Fri Jan 08 13:47:01 2010 -0800 +++ b/src/share/vm/opto/parse.hpp Fri Jan 08 13:58:49 2010 -0800 @@ -39,6 +39,7 @@ // 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 @@ 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 @@ 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 {