[llvm] [IR] LangRef: document behavior of double-lifetime.start (PR #184296)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 3 03:40:49 PST 2026
================
@@ -27726,15 +27726,18 @@ value.
Semantics:
""""""""""
-If ``ptr`` is a ``poison`` value, the intrinsic has no effect.
+If ``ptr`` is a ``poison`` value or not a pointer to a stack-allocated object,
----------------
nikic wrote:
Yes, phi nodes are not allowed.
Poison is only allowed so that dead allocas can be replaced with poison. That's also why your "no effect" -> "Undefined Behavior" change is incorrect. Lifetime intrinsics with poison argument must have no effect.
Poison monotonicity is not relevant here, specifically because these intrinsics do not take arbitrary values.
https://github.com/llvm/llvm-project/pull/184296
More information about the llvm-commits
mailing list