Lokasi ngalangkungan proxy:   [ UP ]  
[Ngawartoskeun bug]   [Panyetelan cookie]                
Skip to content

ICorDebugGCReferenceEnum does not enumerate CorGCReferenceType::CorReferenceFinalizer #39333

Closed

Description

@willxie-eng

Description

The finalizer queue segment enumeration appears to be not implemented. See here: https://github.com/dotnet/runtime/blob/master/src/coreclr/src/debug/daccess/dacdbiimpl.cpp#L7488, mFQStart/mFQEnd is set to null and never updated.

Configuration

This potentially affects all .NET Framework & Core (all versions). I tested using .NET 4.8.4180.0 on Windows 19041.329. This would affect both x86 and x64 configuration (not sure about ARM).

Regression?

N/A

Other information

Current workarounds would be to use CLRMD (via SOS & DAC) to get finalizer queue address start/end or leveraging ICorProfiler apis for Finalizer callbacks.

Activity

  1. Dotnet-GitSync-Bot commented on Jul 14, 2020

    @Dotnet-GitSync-Bot
    Collaborator

    I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label.

  2. added
    untriaged
    on Jul 14, 2020
  3. willxie-eng commented on Jul 14, 2020

    @willxie-eng
    Author

    area-Diagnostics-coreclr @tommcdon

  4. josalem commented on Jul 15, 2020

    @josalem
    Contributor

    CC @dotnet/dotnet-diag @mikem8361

  5. added this to the 6.0.0 milestone on Jul 15, 2020
  6. removed
    untriaged
    on Jul 20, 2020
  7. tommcdon commented on Jul 20, 2020

    @tommcdon
    Member
  8. davmason commented on Jul 20, 2020

    @davmason
    Contributor

    I looked at this last week with @WilliamXieMSFT, it's just plain broken and there's no workaround to make the API work.

    The options for getting finalizer references are:

    • Ask us to fix this API, which wouldn't happen until .net 6 at the earliest and won't be backported
    • Use the same approach SOS does to scan the finalizer queue, where you call in to the DAC to get the address of the finalizer queue and then manually walk it
    • Use ICorProfilerCallback::FinalizeableObjectQueued to get notified of objects as they are put in the finalizer queue
  9. added
    enhancement
    on Nov 6, 2020
  10. modified the milestones: 6.0.0, Future on Mar 12, 2021
  11. dotnet-policy-service commented on Sep 12, 2025

    @dotnet-policy-service
    Contributor

    Due to lack of recent activity, this issue has been marked as a candidate for backlog cleanup. It will be closed if no further activity occurs within 14 more days. Any new comment (by anyone, not necessarily the author) will undo this process.

    This process is part of our issue cleanup automation.

  12. added
    backlog-cleanup-candidate
    on Sep 12, 2025
  13. dotnet-policy-service commented on Sep 26, 2025

    @dotnet-policy-service
    Contributor

    This issue will now be closed since it had been marked no-recent-activity but received no further activity in the past 14 days. It is still possible to reopen or comment on the issue, but please note that the issue will be locked if it remains inactive for another 30 days.

  14. removed this from the Future milestone on Sep 26, 2025
  15. locked and limited conversation to collaborators on Oct 26, 2025
  16. removed
    backlog-cleanup-candidate
    on Oct 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-Diagnostics-coreclrenhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions