Skip to content

[Local GC] Handle table and the DAC #8322

@swgillespie

Description

@swgillespie

This is an issue that @adityamandaleeka ran into a little while ago. The DAC has deep knowledge of the GC's handle table:

  • It is aware of the global handle table map instance, g_HandleTableMap
  • It calls GetDependentHandleSecondary on handles in the target process
  • It calls HndGetHandleExtraInfo on handles in the target process

Today, this is not a problem; the GC DAC build compiles the above two functions into the DAC and the DAC is free to call them. For a standalone GC, this is more problematic; as it stands today the DAC is not permitted to dispatch virtually on the target's IGCHeap instance, which it would need to do for these two functions. Even if it could, it would not be calling the DACCESS_COMPILE versions of these functions, which could result in strange behavior.

This commit (swgillespie/coreclr@1eef14c) is a start - it fixes the first bullet point and ifdef's out the bottom two bullet points. We'll need to come up with some sort of strategy GetDependentHandleSecondary and HndGetHandleExtraInfo - we can allow the debugger to dispatch virtually on the debugee's IGCHeap instance, duplicate the code, or do some other solution.

This issue is the last remaining use of the GC DAC build and, once it is complete, the GC DAC build can be removed completely which should be a nice DAC binary size win and compile time improvement.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions