src/hotspot/share/opto/compile.hpp
changeset 53594 47a8fdf84424
parent 53430 ccfd4e614bb8
child 53625 0a9dfdbb01d1
equal deleted inserted replaced
53593:1ceebbe2c1da 53594:47a8fdf84424
   381   int                   _orig_pc_slot_offset_in_bytes;
   381   int                   _orig_pc_slot_offset_in_bytes;
   382 
   382 
   383   int                   _major_progress;        // Count of something big happening
   383   int                   _major_progress;        // Count of something big happening
   384   bool                  _inlining_progress;     // progress doing incremental inlining?
   384   bool                  _inlining_progress;     // progress doing incremental inlining?
   385   bool                  _inlining_incrementally;// Are we doing incremental inlining (post parse)
   385   bool                  _inlining_incrementally;// Are we doing incremental inlining (post parse)
       
   386   bool                  _do_cleanup;            // Cleanup is needed before proceeding with incremental inlining
   386   bool                  _has_loops;             // True if the method _may_ have some loops
   387   bool                  _has_loops;             // True if the method _may_ have some loops
   387   bool                  _has_split_ifs;         // True if the method _may_ have some split-if
   388   bool                  _has_split_ifs;         // True if the method _may_ have some split-if
   388   bool                  _has_unsafe_access;     // True if the method _may_ produce faults in unsafe loads or stores.
   389   bool                  _has_unsafe_access;     // True if the method _may_ produce faults in unsafe loads or stores.
   389   bool                  _has_stringbuilder;     // True StringBuffers or StringBuilders are allocated
   390   bool                  _has_stringbuilder;     // True StringBuffers or StringBuilders are allocated
   390   bool                  _has_boxed_value;       // True if a boxed object is allocated
   391   bool                  _has_boxed_value;       // True if a boxed object is allocated
   651   int               major_progress() const      { return _major_progress; }
   652   int               major_progress() const      { return _major_progress; }
   652   void          set_inlining_progress(bool z)   { _inlining_progress = z; }
   653   void          set_inlining_progress(bool z)   { _inlining_progress = z; }
   653   int               inlining_progress() const   { return _inlining_progress; }
   654   int               inlining_progress() const   { return _inlining_progress; }
   654   void          set_inlining_incrementally(bool z) { _inlining_incrementally = z; }
   655   void          set_inlining_incrementally(bool z) { _inlining_incrementally = z; }
   655   int               inlining_incrementally() const { return _inlining_incrementally; }
   656   int               inlining_incrementally() const { return _inlining_incrementally; }
       
   657   void          set_do_cleanup(bool z)          { _do_cleanup = z; }
       
   658   int               do_cleanup() const          { return _do_cleanup; }
   656   void          set_major_progress()            { _major_progress++; }
   659   void          set_major_progress()            { _major_progress++; }
   657   void        clear_major_progress()            { _major_progress = 0; }
   660   void        clear_major_progress()            { _major_progress = 0; }
   658   int               max_inline_size() const     { return _max_inline_size; }
   661   int               max_inline_size() const     { return _max_inline_size; }
   659   void          set_freq_inline_size(int n)     { _freq_inline_size = n; }
   662   void          set_freq_inline_size(int n)     { _freq_inline_size = n; }
   660   int               freq_inline_size() const    { return _freq_inline_size; }
   663   int               freq_inline_size() const    { return _freq_inline_size; }
  1073 
  1076 
  1074   bool over_inlining_cutoff() const {
  1077   bool over_inlining_cutoff() const {
  1075     if (!inlining_incrementally()) {
  1078     if (!inlining_incrementally()) {
  1076       return unique() > (uint)NodeCountInliningCutoff;
  1079       return unique() > (uint)NodeCountInliningCutoff;
  1077     } else {
  1080     } else {
  1078       return live_nodes() > (uint)LiveNodeCountInliningCutoff;
  1081       // Give some room for incremental inlining algorithm to "breathe"
       
  1082       // and avoid thrashing when live node count is close to the limit.
       
  1083       // Keep in mind that live_nodes() isn't accurate during inlining until
       
  1084       // dead node elimination step happens (see Compile::inline_incrementally).
       
  1085       return live_nodes() > (uint)LiveNodeCountInliningCutoff * 11 / 10;
  1079     }
  1086     }
  1080   }
  1087   }
  1081 
  1088 
  1082   void inc_number_of_mh_late_inlines() { _number_of_mh_late_inlines++; }
  1089   void inc_number_of_mh_late_inlines() { _number_of_mh_late_inlines++; }
  1083   void dec_number_of_mh_late_inlines() { assert(_number_of_mh_late_inlines > 0, "_number_of_mh_late_inlines < 0 !"); _number_of_mh_late_inlines--; }
  1090   void dec_number_of_mh_late_inlines() { assert(_number_of_mh_late_inlines > 0, "_number_of_mh_late_inlines < 0 !"); _number_of_mh_late_inlines--; }
  1084   bool has_mh_late_inlines() const     { return _number_of_mh_late_inlines > 0; }
  1091   bool has_mh_late_inlines() const     { return _number_of_mh_late_inlines > 0; }
  1085 
  1092 
  1086   void inline_incrementally_one(PhaseIterGVN& igvn);
  1093   bool inline_incrementally_one();
       
  1094   void inline_incrementally_cleanup(PhaseIterGVN& igvn);
  1087   void inline_incrementally(PhaseIterGVN& igvn);
  1095   void inline_incrementally(PhaseIterGVN& igvn);
  1088   void inline_string_calls(bool parse_time);
  1096   void inline_string_calls(bool parse_time);
  1089   void inline_boxing_calls(PhaseIterGVN& igvn);
  1097   void inline_boxing_calls(PhaseIterGVN& igvn);
  1090   bool optimize_loops(PhaseIterGVN& igvn, LoopOptsMode mode);
  1098   bool optimize_loops(PhaseIterGVN& igvn, LoopOptsMode mode);
  1091   void remove_root_to_sfpts_edges(PhaseIterGVN& igvn);
  1099   void remove_root_to_sfpts_edges(PhaseIterGVN& igvn);