[PATCH] D97673: [RFC] [[Coroutine] [Debug] Salvage dbg.value at O2

Jeremy Morse via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 24 08:39:21 PDT 2021


jmorse added inline comments.


================
Comment at: llvm/test/Transforms/Coroutines/coro-debug-dbg.values-O2.ll:6-8
+; CHECK:       entry.resume:
+; CHECK:         call void @llvm.dbg.value(metadata %f.Frame** %FramePtr{{.*}}, metadata ![[IVAR_RESUME:[0-9]+]], metadata !DIExpression(
+; CHECK:         call void @llvm.dbg.value(metadata %f.Frame** %FramePtr{{.*}}, metadata ![[JVAR_RESUME:[0-9]+]], metadata !DIExpression(
----------------
jmorse wrote:
> nit: IMO you should check that the `dbg.value`s operand is a specific LLVM-IR value (i.e., the frame pointer), rather than just checking the type. That protects against some future optimisation or error producing a pointer-typed `undef` as the `dbg.value` operand.
Scratch that, I didn't notice you were already doing that.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D97673/new/

https://reviews.llvm.org/D97673



More information about the llvm-commits mailing list