[llvm-dev] [RFC] Generate Debug Information for Labels in Function
via llvm-dev
llvm-dev at lists.llvm.org
Thu Mar 29 10:55:32 PDT 2018
> -----Original Message-----
> From: llvm-dev [mailto:llvm-dev-bounces at lists.llvm.org] On Behalf Of via
> llvm-dev
> Sent: Thursday, March 29, 2018 1:54 PM
> To: aprantl at apple.com; hsiangkai at gmail.com
> Cc: llvm-dev at lists.llvm.org
> Subject: Re: [llvm-dev] [RFC] Generate Debug Information for Labels in
> Function
>
> > Based on that I think it might be sufficient to have a flag on an IR
> label
> > that marks a user-originated label and triggers the backend to create a
> > DW_TAG_label for it. If we do need source location information for the
> > DW_TAG_label, we could grab it from the first instruction.
>
> Are there languages where labels are scoped? If so we'd need explicit
> metadata to identify the parent scope. In C/C++ the only scope is the
> containing function, which I'm guessing we wouldn't need to specify
> (except for inlined functions? that might need some care to get right).
>
> I feel compelled to point out that the top instructions in a block do not
> necessarily have a valid source location so we might want to carry that
> explicitly just for sanity's sake.
That is, carry the source location explicitly on the label.
> --paulr
>
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
More information about the llvm-dev
mailing list