Uploaded image for project: 'Harmony'
  1. Harmony
  2. HARMONY-5135

[drlvm]DRL VM hangs during stress.Mix running on x86-64

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • None
    • DRLVM
    • None
    • Linux x86-64
    • Advanced

    Description

      The safe_point called from hycond_wait, which called from many places include locktable_reader_enter and locktable_writer_enter.
      From other side access to locatable there is in function hythread_reclaim_recources, which works during stop the world.
      It leads to dead lock, when first thread, which catch locktable monitor goes into safe poin and GC starts. In this case GC can't complete work, because one or several threads waiting on following stack, when first thread free locktable monitor:

      #1 <pthread_mutex_lock>
      #2 <hymutex_lock>
      #3<hythread_reclaim_resources>
      #4 <vm_reclaim_native_objs>
      #5 <gc_reclaim_heap>
      #6 <fspace_alloc>
      #7 ....

      So it's a deadlock when firs thread waits when second thread free monitor, and send thread waits when first thread free the other monitor.

      Attachments

        1. lock_table_fix.patch
          3 kB
          Pavel Rebriy

        Issue Links

          Activity

            People

              gshimansky Gregory Shimansky
              pavel.n.afremov Pavel Afremov
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Slack

                  Issue deployment