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

occasional false assert thrown by JRT_LEAF routines

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 1.4.2
    • 1.4.1
    • hotspot
    • mantis
    • generic
    • generic

      I made about 73 SpecApplication runs, over about 50 CPU hours.
      The runs were 3 at a time on Krajy, a 4-way machine.
      Eight runs raised the following assertion from gcLocker.cpp:
        assert(!h->gc_is_active(), "GC active during No_GC_Verifier")

      (NOTE: There were also 2 failures with the message "Fatal: not a call imm32".
      These were a more serious unrelated bug, 4681417.)

      Here is a backtrace from one of the runs:

        [6] report_assertion_failure(code_str = ???, file_name = ???, line_no = ???, message = ???) (optimized), at 0xdebceae1 (line ~144) in "jrose/hopper/src/share/vm/utilities/debug.cpp"
        [7] No_GC_Verifier::No_GC_Verifier(this = ???, activate = ???) (optimized), at 0xdec2f38e (line ~27) in "jrose/hopper/src/share/vm/memory/gcLocker.cpp"
        [8] SharedRuntime::d2i(x = ???) (optimized), at 0xdf16b3f8 (line ~103) in "jrose/hopper/src/share/vm/runtime/sharedRuntime.cpp"
        [9] ConvD2INode::Value(this = ???, phase = ???) (optimized), at 0xdebbd89a (line ~554) in "jrose/hopper/src/share/vm/opto/connode.cpp"

      The assertion check is noticing that the C2 optimizer is calling
      the JRT_LEAF routine SharedRuntime::d2i, while a GC is in progress.
      Although this is harmless since the compiler runs in the state
      _thread_in_native, the assertion is overly conservative, since
      JRT_LEAF routines were designed to be called from Java code,
      not C code.

      Inspection of the code suggests that the only place where non-Java
      code is calling JRT_LEAF routines is in opto/connode.cpp, in four
      places. However, the interface is publicly available to all C code,
      and it is impossible to ensure that C routines will not call leaf
      routines.

            acorn Karen Kinnear (Inactive)
            jrose John Rose
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: