Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8359057

AbstractInterpreter::is_not_reached returns incorrectly with invokedynamic

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P4 P4
    • 26
    • 26
    • hotspot

      In JDK-8301995, handling of invokedynamic in the constant pool cache was refactored and a regression was introduced in AbstractInterpreter::is_not_reached(). Before the patch the code looked like this:

      case Bytecodes::_invokedynamic: {
              assert(invoke_bc.has_index_u4(code), "sanity");
              int method_index = invoke_bc.get_index_u4(code);
              return cpool->invokedynamic_cp_cache_entry_at(method_index)->is_f1_null();
      }

      The patch introduced this change:

      case Bytecodes::_invokedynamic: {
              assert(invoke_bc.has_index_u4(code), "sanity");
              int method_index = invoke_bc.get_index_u4(code);
              return cpool->resolved_indy_entry_at(method_index)->is_resolved();
      }
       The new return should be negated to match the pre-patch result.

            matsaave Matias Saavedra Silva
            matsaave Matias Saavedra Silva
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: