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

Allow to reliably disable gc for objects created with the debugger

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P3 P3
    • tbd
    • 22
    • core-svc
    • None

      Currently if only one thread is suspended in the debugged process,
      the resulting object of:
         any InvokeMethod
         ClassType.NewInstance
         ArrayType.NewInstance
         CreateString
      commands may be garbage collected immediately. And even the subsequent DisableCollection command for such objects will already fail.
      This leads to ugly workarounds like doing:
         CreateString - DisableCollection
      in a loop to get the new string mirror reliably.

      That would be great to have a reliable solution for such cases.

            cjplummer Chris Plummer
            eushakov Egor Ushakov
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: