Skip to content

Garbage collection intrinsics and debugging intrinsics don't mix #9642

@llvmbot

Description

@llvmbot
Bugzilla Link 9270
Version trunk
OS All
Reporter LLVM Bugzilla Contributor

Extended Description

It appears that the presence of llvm.gcroot intrinsics cause the code generator to emit improper DWARF debugging information. I have two sample files, one which was generated with garbage collection enabled (Hello.ll) and another with garbage collection disabled (Hello2.ll). I've also included the original source file (Hello.tart).

To demonstrate the problem, compile both samples and enter the debugger, setting a breakpoint on 'main'.

In the first sample, with GC, the debugger stops on line 3 "let s2 = s" which is incorrect, because line 2 has not executed yet.

In the second sample, without GC, the debugger stops on the line 2 "var s = getString()", which is correct.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugzillaIssues migrated from bugzilla

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions