Make TraceDeoptimization a diagnostic flag

XMLWordPrintable

    • b27

      Many times I wish I had TraceDeoptimization available in a product build just to find it's a develop flag. In general, deoptimization is a very expensive operation so the overhead of an additional check is negligible.

      Although there is one place where it could matter:

      StackValueCollection* interpretedVFrame::stack_data(bool expressions) const {

        InterpreterOopMap oop_mask;
        // oopmap for current bci
        if ((TraceDeoptimization && Verbose) JVMCI_ONLY( || PrintDeoptimizationDetails)) {
          methodHandle m_h(Thread::current(), method());
          OopMapCache::compute_one_oop_map(m_h, bci(), &oop_mask);
        } else {
          method()->mask_for(bci(), &oop_mask);
        }

      This method is used by various stack walking code in the VM and it might affect performance. Doing performance evaluation should give us an answer.

            Assignee:
            Tobias Holenstein
            Reporter:
            Christian Thalinger (Inactive)
            Votes:
            6 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: