Skip to content

Commit ed7f36e

Browse files
authored
[LangRef] update a couple of struct/vector creation examples to use poison
1 parent e9be217 commit ed7f36e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

llvm/docs/LangRef.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10827,9 +10827,9 @@ Example:
1082710827

1082810828
.. code-block:: llvm
1082910829

10830-
%agg1 = insertvalue {i32, float} undef, i32 1, 0 ; yields {i32 1, float undef}
10831-
%agg2 = insertvalue {i32, float} %agg1, float %val, 1 ; yields {i32 1, float %val}
10832-
%agg3 = insertvalue {i32, {float}} undef, float %val, 1, 0 ; yields {i32 undef, {float %val}}
10830+
%agg1 = insertvalue {i32, float} poison, i32 1, 0 ; yields {i32 1, float poison}
10831+
%agg2 = insertvalue {i32, float} %agg1, float %val, 1 ; yields {i32 1, float %val}
10832+
%agg3 = insertvalue {i32, {float}} poison, float %val, 1, 0 ; yields {i32 poison, {float %val}}
1083310833

1083410834
.. _memoryops:
1083510835

@@ -20876,7 +20876,7 @@ Example:
2087620876

2087720877
;;; Expansion.
2087820878
;; Lanes at and above %pivot are taken from %on_false
20879-
%atfirst = insertelement <4 x i32> undef, i32 %pivot, i32 0
20879+
%atfirst = insertelement <4 x i32> poison, i32 %pivot, i32 0
2088020880
%splat = shufflevector <4 x i32> %atfirst, <4 x i32> poison, <4 x i32> zeroinitializer
2088120881
%pivotmask = icmp ult <4 x i32> <i32 0, i32 1, i32 2, i32 3>, <4 x i32> %splat
2088220882
%mergemask = and <4 x i1> %cond, <4 x i1> %pivotmask

0 commit comments

Comments
 (0)