[llvm] 7cfdd2a - [NFC][AMDGPU] Replace undef with poison in cast.ll, fptosi.ll and fptoui.ll (#223570)

via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 15 01:55:47 PDT 2026


Author: Dmitry Sidorov
Date: 2026-09-15T10:55:39+02:00
New Revision: 7cfdd2a6f4a1eef5715fca3055351cf6bc8958b1

URL: https://github.com/llvm/llvm-project/commit/7cfdd2a6f4a1eef5715fca3055351cf6bc8958b1
DIFF: https://github.com/llvm/llvm-project/commit/7cfdd2a6f4a1eef5715fca3055351cf6bc8958b1.diff

LOG: [NFC][AMDGPU] Replace undef with poison in cast.ll, fptosi.ll and fptoui.ll (#223570)

<sub>Stack created with <a
href="https://github.com/github/gh-stack">GitHub Stacks CLI</a> • <a
href="https://gh.io/stacks-feedback">Give Feedback 💬</a></sub>

Added: 
    

Modified: 
    llvm/test/Analysis/CostModel/AMDGPU/cast.ll
    llvm/test/Analysis/CostModel/AMDGPU/fptosi.ll
    llvm/test/Analysis/CostModel/AMDGPU/fptoui.ll

Removed: 
    


################################################################################
diff  --git a/llvm/test/Analysis/CostModel/AMDGPU/cast.ll b/llvm/test/Analysis/CostModel/AMDGPU/cast.ll
index 65d1eacfbb611..934d99b5a012b 100644
--- a/llvm/test/Analysis/CostModel/AMDGPU/cast.ll
+++ b/llvm/test/Analysis/CostModel/AMDGPU/cast.ll
@@ -13,233 +13,233 @@
 define i32 @add(i32 %arg) {
   ; -- Same size registeres --
 ; ALL-LABEL: 'add'
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A = zext <4 x i1> undef to <4 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %B = sext <4 x i1> undef to <4 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = trunc <4 x i32> undef to <4 x i1>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D = zext <8 x i1> undef to <8 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %E = sext <8 x i1> undef to <8 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %F = trunc <8 x i32> undef to <8 x i1>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %G = zext i1 undef to i32
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %H = trunc i32 undef to i1
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A = zext <4 x i1> poison to <4 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %B = sext <4 x i1> poison to <4 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = trunc <4 x i32> poison to <4 x i1>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D = zext <8 x i1> poison to <8 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %E = sext <8 x i1> poison to <8 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %F = trunc <8 x i32> poison to <8 x i1>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %G = zext i1 poison to i32
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %H = trunc i32 poison to i1
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'add'
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A = zext <4 x i1> undef to <4 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %B = sext <4 x i1> undef to <4 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = trunc <4 x i32> undef to <4 x i1>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D = zext <8 x i1> undef to <8 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %E = sext <8 x i1> undef to <8 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %F = trunc <8 x i32> undef to <8 x i1>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %G = zext i1 undef to i32
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %H = trunc i32 undef to i1
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A = zext <4 x i1> poison to <4 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %B = sext <4 x i1> poison to <4 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = trunc <4 x i32> poison to <4 x i1>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D = zext <8 x i1> poison to <8 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %E = sext <8 x i1> poison to <8 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %F = trunc <8 x i32> poison to <8 x i1>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %G = zext i1 poison to i32
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %H = trunc i32 poison to i1
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %A = zext <4 x i1> undef to <4 x i32>
-  %B = sext <4 x i1> undef to <4 x i32>
-  %C = trunc <4 x i32> undef to <4 x i1>
+  %A = zext <4 x i1> poison to <4 x i32>
+  %B = sext <4 x i1> poison to <4 x i32>
+  %C = trunc <4 x i32> poison to <4 x i1>
 
   ; -- Different size registers --
-  %D = zext <8 x i1> undef to <8 x i32>
-  %E = sext <8 x i1> undef to <8 x i32>
-  %F = trunc <8 x i32> undef to <8 x i1>
+  %D = zext <8 x i1> poison to <8 x i32>
+  %E = sext <8 x i1> poison to <8 x i32>
+  %F = trunc <8 x i32> poison to <8 x i1>
 
   ; -- scalars --
-  %G = zext i1 undef to i32
-  %H = trunc i32 undef to i1
+  %G = zext i1 poison to i32
+  %H = trunc i32 poison to i1
 
-  ret i32 undef
+  ret i32 poison
 }
 
 define i32 @zext_sext(<8 x i1> %in) {
 ; FAST-LABEL: 'zext_sext'
 ; FAST-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %Z = zext <8 x i1> %in to <8 x i32>
 ; FAST-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %S = sext <8 x i1> %in to <8 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A1 = zext <16 x i8> undef to <16 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A2 = sext <16 x i8> undef to <16 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A = sext <8 x i16> undef to <8 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %B = zext <8 x i16> undef to <8 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = sext <4 x i32> undef to <4 x i64>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v8i8.z = zext <8 x i8> undef to <8 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.s = sext <8 x i8> undef to <8 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i16.z = zext <4 x i16> undef to <4 x i64>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i16.s = sext <4 x i16> undef to <4 x i64>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i8.z = zext <4 x i8> undef to <4 x i64>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i8.s = sext <4 x i8> undef to <4 x i64>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D = zext <4 x i32> undef to <4 x i64>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D1 = zext <8 x i32> undef to <8 x i64>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D2 = sext <8 x i32> undef to <8 x i64>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D3 = zext <16 x i16> undef to <16 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D4 = zext <16 x i8> undef to <16 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D5 = zext <16 x i1> undef to <16 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %E = trunc <4 x i64> undef to <4 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F = trunc <8 x i32> undef to <8 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F1 = trunc <16 x i16> undef to <16 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F2 = trunc <8 x i32> undef to <8 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F3 = trunc <4 x i64> undef to <4 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G = trunc <8 x i64> undef to <8 x i32>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G1 = trunc <16 x i32> undef to <16 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G2 = trunc <16 x i32> undef to <16 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; FAST-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A1 = zext <16 x i8> poison to <16 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A2 = sext <16 x i8> poison to <16 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A = sext <8 x i16> poison to <8 x i32>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %B = zext <8 x i16> poison to <8 x i32>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = sext <4 x i32> poison to <4 x i64>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v8i8.z = zext <8 x i8> poison to <8 x i32>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.s = sext <8 x i8> poison to <8 x i32>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i16.z = zext <4 x i16> poison to <4 x i64>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i16.s = sext <4 x i16> poison to <4 x i64>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i8.z = zext <4 x i8> poison to <4 x i64>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i8.s = sext <4 x i8> poison to <4 x i64>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D = zext <4 x i32> poison to <4 x i64>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D1 = zext <8 x i32> poison to <8 x i64>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D2 = sext <8 x i32> poison to <8 x i64>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D3 = zext <16 x i16> poison to <16 x i32>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D4 = zext <16 x i8> poison to <16 x i32>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D5 = zext <16 x i1> poison to <16 x i32>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %E = trunc <4 x i64> poison to <4 x i32>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F = trunc <8 x i32> poison to <8 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F1 = trunc <16 x i16> poison to <16 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F2 = trunc <8 x i32> poison to <8 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F3 = trunc <4 x i64> poison to <4 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G = trunc <8 x i64> poison to <8 x i32>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G1 = trunc <16 x i32> poison to <16 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G2 = trunc <16 x i32> poison to <16 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; SLOW-LABEL: 'zext_sext'
 ; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %Z = zext <8 x i1> %in to <8 x i32>
 ; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %S = sext <8 x i1> %in to <8 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A1 = zext <16 x i8> undef to <16 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A2 = sext <16 x i8> undef to <16 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A = sext <8 x i16> undef to <8 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %B = zext <8 x i16> undef to <8 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = sext <4 x i32> undef to <4 x i64>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.z = zext <8 x i8> undef to <8 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.s = sext <8 x i8> undef to <8 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i16.z = zext <4 x i16> undef to <4 x i64>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i16.s = sext <4 x i16> undef to <4 x i64>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i8.z = zext <4 x i8> undef to <4 x i64>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i8.s = sext <4 x i8> undef to <4 x i64>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D = zext <4 x i32> undef to <4 x i64>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D1 = zext <8 x i32> undef to <8 x i64>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D2 = sext <8 x i32> undef to <8 x i64>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D3 = zext <16 x i16> undef to <16 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D4 = zext <16 x i8> undef to <16 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D5 = zext <16 x i1> undef to <16 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %E = trunc <4 x i64> undef to <4 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F = trunc <8 x i32> undef to <8 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F1 = trunc <16 x i16> undef to <16 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F2 = trunc <8 x i32> undef to <8 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F3 = trunc <4 x i64> undef to <4 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G = trunc <8 x i64> undef to <8 x i32>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G1 = trunc <16 x i32> undef to <16 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G2 = trunc <16 x i32> undef to <16 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A1 = zext <16 x i8> poison to <16 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A2 = sext <16 x i8> poison to <16 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A = sext <8 x i16> poison to <8 x i32>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %B = zext <8 x i16> poison to <8 x i32>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = sext <4 x i32> poison to <4 x i64>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.z = zext <8 x i8> poison to <8 x i32>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.s = sext <8 x i8> poison to <8 x i32>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i16.z = zext <4 x i16> poison to <4 x i64>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i16.s = sext <4 x i16> poison to <4 x i64>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i8.z = zext <4 x i8> poison to <4 x i64>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i8.s = sext <4 x i8> poison to <4 x i64>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D = zext <4 x i32> poison to <4 x i64>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D1 = zext <8 x i32> poison to <8 x i64>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D2 = sext <8 x i32> poison to <8 x i64>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D3 = zext <16 x i16> poison to <16 x i32>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D4 = zext <16 x i8> poison to <16 x i32>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D5 = zext <16 x i1> poison to <16 x i32>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %E = trunc <4 x i64> poison to <4 x i32>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F = trunc <8 x i32> poison to <8 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F1 = trunc <16 x i16> poison to <16 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F2 = trunc <8 x i32> poison to <8 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F3 = trunc <4 x i64> poison to <4 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G = trunc <8 x i64> poison to <8 x i32>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G1 = trunc <16 x i32> poison to <16 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G2 = trunc <16 x i32> poison to <16 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; FAST-SIZE-LABEL: 'zext_sext'
 ; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %Z = zext <8 x i1> %in to <8 x i32>
 ; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %S = sext <8 x i1> %in to <8 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A1 = zext <16 x i8> undef to <16 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A2 = sext <16 x i8> undef to <16 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A = sext <8 x i16> undef to <8 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %B = zext <8 x i16> undef to <8 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = sext <4 x i32> undef to <4 x i64>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v8i8.z = zext <8 x i8> undef to <8 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.s = sext <8 x i8> undef to <8 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i16.z = zext <4 x i16> undef to <4 x i64>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i16.s = sext <4 x i16> undef to <4 x i64>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i8.z = zext <4 x i8> undef to <4 x i64>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i8.s = sext <4 x i8> undef to <4 x i64>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D = zext <4 x i32> undef to <4 x i64>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D1 = zext <8 x i32> undef to <8 x i64>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D2 = sext <8 x i32> undef to <8 x i64>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D3 = zext <16 x i16> undef to <16 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D4 = zext <16 x i8> undef to <16 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D5 = zext <16 x i1> undef to <16 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %E = trunc <4 x i64> undef to <4 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F = trunc <8 x i32> undef to <8 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F1 = trunc <16 x i16> undef to <16 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F2 = trunc <8 x i32> undef to <8 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F3 = trunc <4 x i64> undef to <4 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G = trunc <8 x i64> undef to <8 x i32>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G1 = trunc <16 x i32> undef to <16 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G2 = trunc <16 x i32> undef to <16 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A1 = zext <16 x i8> poison to <16 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A2 = sext <16 x i8> poison to <16 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A = sext <8 x i16> poison to <8 x i32>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %B = zext <8 x i16> poison to <8 x i32>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = sext <4 x i32> poison to <4 x i64>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v8i8.z = zext <8 x i8> poison to <8 x i32>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.s = sext <8 x i8> poison to <8 x i32>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i16.z = zext <4 x i16> poison to <4 x i64>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i16.s = sext <4 x i16> poison to <4 x i64>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i8.z = zext <4 x i8> poison to <4 x i64>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i8.s = sext <4 x i8> poison to <4 x i64>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D = zext <4 x i32> poison to <4 x i64>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D1 = zext <8 x i32> poison to <8 x i64>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D2 = sext <8 x i32> poison to <8 x i64>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D3 = zext <16 x i16> poison to <16 x i32>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D4 = zext <16 x i8> poison to <16 x i32>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D5 = zext <16 x i1> poison to <16 x i32>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %E = trunc <4 x i64> poison to <4 x i32>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F = trunc <8 x i32> poison to <8 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F1 = trunc <16 x i16> poison to <16 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F2 = trunc <8 x i32> poison to <8 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F3 = trunc <4 x i64> poison to <4 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G = trunc <8 x i64> poison to <8 x i32>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G1 = trunc <16 x i32> poison to <16 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G2 = trunc <16 x i32> poison to <16 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
 ; SLOW-SIZE-LABEL: 'zext_sext'
 ; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %Z = zext <8 x i1> %in to <8 x i32>
 ; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %S = sext <8 x i1> %in to <8 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A1 = zext <16 x i8> undef to <16 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A2 = sext <16 x i8> undef to <16 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A = sext <8 x i16> undef to <8 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %B = zext <8 x i16> undef to <8 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = sext <4 x i32> undef to <4 x i64>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.z = zext <8 x i8> undef to <8 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.s = sext <8 x i8> undef to <8 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i16.z = zext <4 x i16> undef to <4 x i64>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i16.s = sext <4 x i16> undef to <4 x i64>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i8.z = zext <4 x i8> undef to <4 x i64>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i8.s = sext <4 x i8> undef to <4 x i64>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D = zext <4 x i32> undef to <4 x i64>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D1 = zext <8 x i32> undef to <8 x i64>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D2 = sext <8 x i32> undef to <8 x i64>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D3 = zext <16 x i16> undef to <16 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D4 = zext <16 x i8> undef to <16 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D5 = zext <16 x i1> undef to <16 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %E = trunc <4 x i64> undef to <4 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F = trunc <8 x i32> undef to <8 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F1 = trunc <16 x i16> undef to <16 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F2 = trunc <8 x i32> undef to <8 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F3 = trunc <4 x i64> undef to <4 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G = trunc <8 x i64> undef to <8 x i32>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G1 = trunc <16 x i32> undef to <16 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G2 = trunc <16 x i32> undef to <16 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A1 = zext <16 x i8> poison to <16 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %A2 = sext <16 x i8> poison to <16 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A = sext <8 x i16> poison to <8 x i32>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %B = zext <8 x i16> poison to <8 x i32>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C = sext <4 x i32> poison to <4 x i64>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.z = zext <8 x i8> poison to <8 x i32>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %C.v8i8.s = sext <8 x i8> poison to <8 x i32>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i16.z = zext <4 x i16> poison to <4 x i64>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i16.s = sext <4 x i16> poison to <4 x i64>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %C.v4i8.z = zext <4 x i8> poison to <4 x i64>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %C.v4i8.s = sext <4 x i8> poison to <4 x i64>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D = zext <4 x i32> poison to <4 x i64>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %D1 = zext <8 x i32> poison to <8 x i64>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %D2 = sext <8 x i32> poison to <8 x i64>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D3 = zext <16 x i16> poison to <16 x i32>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D4 = zext <16 x i8> poison to <16 x i32>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %D5 = zext <16 x i1> poison to <16 x i32>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %E = trunc <4 x i64> poison to <4 x i32>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F = trunc <8 x i32> poison to <8 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F1 = trunc <16 x i16> poison to <16 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F2 = trunc <8 x i32> poison to <8 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %F3 = trunc <4 x i64> poison to <4 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G = trunc <8 x i64> poison to <8 x i32>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G1 = trunc <16 x i32> poison to <16 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %G2 = trunc <16 x i32> poison to <16 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
   %Z = zext <8 x i1> %in to <8 x i32>
   %S = sext <8 x i1> %in to <8 x i32>
 
-  %A1 = zext <16 x i8> undef to <16 x i16>
-  %A2 = sext <16 x i8> undef to <16 x i16>
-  %A = sext <8 x i16> undef to <8 x i32>
-  %B = zext <8 x i16> undef to <8 x i32>
-  %C = sext <4 x i32> undef to <4 x i64>
+  %A1 = zext <16 x i8> poison to <16 x i16>
+  %A2 = sext <16 x i8> poison to <16 x i16>
+  %A = sext <8 x i16> poison to <8 x i32>
+  %B = zext <8 x i16> poison to <8 x i32>
+  %C = sext <4 x i32> poison to <4 x i64>
 
-  %C.v8i8.z = zext <8 x i8> undef to <8 x i32>
-  %C.v8i8.s = sext <8 x i8> undef to <8 x i32>
-  %C.v4i16.z = zext <4 x i16> undef to <4 x i64>
-  %C.v4i16.s = sext <4 x i16> undef to <4 x i64>
+  %C.v8i8.z = zext <8 x i8> poison to <8 x i32>
+  %C.v8i8.s = sext <8 x i8> poison to <8 x i32>
+  %C.v4i16.z = zext <4 x i16> poison to <4 x i64>
+  %C.v4i16.s = sext <4 x i16> poison to <4 x i64>
 
-  %C.v4i8.z = zext <4 x i8> undef to <4 x i64>
-  %C.v4i8.s = sext <4 x i8> undef to <4 x i64>
+  %C.v4i8.z = zext <4 x i8> poison to <4 x i64>
+  %C.v4i8.s = sext <4 x i8> poison to <4 x i64>
 
-  %D = zext <4 x i32> undef to <4 x i64>
+  %D = zext <4 x i32> poison to <4 x i64>
 
-  %D1 = zext <8 x i32> undef to <8 x i64>
+  %D1 = zext <8 x i32> poison to <8 x i64>
 
-  %D2 = sext <8 x i32> undef to <8 x i64>
+  %D2 = sext <8 x i32> poison to <8 x i64>
 
-  %D3 = zext <16 x i16> undef to <16 x i32>
-  %D4 = zext <16 x i8> undef to <16 x i32>
-  %D5 = zext <16 x i1> undef to <16 x i32>
+  %D3 = zext <16 x i16> poison to <16 x i32>
+  %D4 = zext <16 x i8> poison to <16 x i32>
+  %D5 = zext <16 x i1> poison to <16 x i32>
 
-  %E = trunc <4 x i64> undef to <4 x i32>
-  %F = trunc <8 x i32> undef to <8 x i16>
-  %F1 = trunc <16 x i16> undef to <16 x i8>
-  %F2 = trunc <8 x i32> undef to <8 x i8>
-  %F3 = trunc <4 x i64> undef to <4 x i8>
+  %E = trunc <4 x i64> poison to <4 x i32>
+  %F = trunc <8 x i32> poison to <8 x i16>
+  %F1 = trunc <16 x i16> poison to <16 x i8>
+  %F2 = trunc <8 x i32> poison to <8 x i8>
+  %F3 = trunc <4 x i64> poison to <4 x i8>
 
-  %G = trunc <8 x i64> undef to <8 x i32>
-  %G1 = trunc <16 x i32> undef to <16 x i16>
-  %G2 = trunc <16 x i32> undef to <16 x i8>
-  ret i32 undef
+  %G = trunc <8 x i64> poison to <8 x i32>
+  %G1 = trunc <16 x i32> poison to <16 x i16>
+  %G2 = trunc <16 x i32> poison to <16 x i8>
+  ret i32 poison
 }
 
 define i32 @masks8(<8 x i1> %in) {
 ; ALL-LABEL: 'masks8'
 ; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %Z = zext <8 x i1> %in to <8 x i32>
 ; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %S = sext <8 x i1> %in to <8 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'masks8'
 ; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %Z = zext <8 x i1> %in to <8 x i32>
 ; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %S = sext <8 x i1> %in to <8 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
   %Z = zext <8 x i1> %in to <8 x i32>
   %S = sext <8 x i1> %in to <8 x i32>
-  ret i32 undef
+  ret i32 poison
 }
 
 define i32 @masks4(<4 x i1> %in) {
 ; ALL-LABEL: 'masks4'
 ; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %Z = zext <4 x i1> %in to <4 x i64>
 ; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %S = sext <4 x i1> %in to <4 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'masks4'
 ; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %Z = zext <4 x i1> %in to <4 x i64>
 ; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %S = sext <4 x i1> %in to <4 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
   %Z = zext <4 x i1> %in to <4 x i64>
   %S = sext <4 x i1> %in to <4 x i64>
-  ret i32 undef
+  ret i32 poison
 }
 
 define void @sitofp4(<4 x i1> %a, <4 x i8> %b, <4 x i16> %c, <4 x i32> %d) {
@@ -402,20 +402,20 @@ define void @fp_conv(<8 x float> %a, <16 x float>%b, <4 x float> %c) {
 ; ALL-LABEL: 'fp_conv'
 ; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A1 = fpext <4 x float> %c to <4 x double>
 ; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A2 = fpext <8 x float> %a to <8 x double>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A3 = fptrunc <4 x double> undef to <4 x float>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A4 = fptrunc <8 x double> undef to <8 x float>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A3 = fptrunc <4 x double> poison to <4 x float>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A4 = fptrunc <8 x double> poison to <8 x float>
 ; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret void
 ;
 ; ALL-SIZE-LABEL: 'fp_conv'
 ; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A1 = fpext <4 x float> %c to <4 x double>
 ; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A2 = fpext <8 x float> %a to <8 x double>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A3 = fptrunc <4 x double> undef to <4 x float>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A4 = fptrunc <8 x double> undef to <8 x float>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %A3 = fptrunc <4 x double> poison to <4 x float>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %A4 = fptrunc <8 x double> poison to <8 x float>
 ; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret void
 ;
   %A1 = fpext <4 x float> %c to <4 x double>
   %A2 = fpext <8 x float> %a to <8 x double>
-  %A3 = fptrunc <4 x double> undef to <4 x float>
-  %A4 = fptrunc <8 x double> undef to <8 x float>
+  %A3 = fptrunc <4 x double> poison to <4 x float>
+  %A4 = fptrunc <8 x double> poison to <8 x float>
   ret void
 }

diff  --git a/llvm/test/Analysis/CostModel/AMDGPU/fptosi.ll b/llvm/test/Analysis/CostModel/AMDGPU/fptosi.ll
index 047d68f488b14..552b0c909f3bf 100644
--- a/llvm/test/Analysis/CostModel/AMDGPU/fptosi.ll
+++ b/llvm/test/Analysis/CostModel/AMDGPU/fptosi.ll
@@ -12,248 +12,248 @@
 
 define i32 @fptosi_double_i64(i32 %arg) {
 ; ALL-LABEL: 'fptosi_double_i64'
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptosi double undef to i64
-; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptosi <2 x double> undef to <2 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptosi <4 x double> undef to <4 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptosi <8 x double> undef to <8 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptosi double poison to i64
+; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptosi <2 x double> poison to <2 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptosi <4 x double> poison to <4 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptosi <8 x double> poison to <8 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'fptosi_double_i64'
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptosi double undef to i64
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptosi <2 x double> undef to <2 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptosi <4 x double> undef to <4 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptosi <8 x double> undef to <8 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptosi double poison to i64
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptosi <2 x double> poison to <2 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptosi <4 x double> poison to <4 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptosi <8 x double> poison to <8 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I64 = fptosi double undef to i64
-  %V2I64 = fptosi <2 x double> undef to <2 x i64>
-  %V4I64 = fptosi <4 x double> undef to <4 x i64>
-  %V8I64 = fptosi <8 x double> undef to <8 x i64>
-  ret i32 undef
+  %I64 = fptosi double poison to i64
+  %V2I64 = fptosi <2 x double> poison to <2 x i64>
+  %V4I64 = fptosi <4 x double> poison to <4 x i64>
+  %V8I64 = fptosi <8 x double> poison to <8 x i64>
+  ret i32 poison
 }
 
 define i32 @fptosi_double_i32(i32 %arg) {
 ; ALL-LABEL: 'fptosi_double_i32'
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptosi double undef to i32
-; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptosi <2 x double> undef to <2 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptosi <4 x double> undef to <4 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptosi <8 x double> undef to <8 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptosi double poison to i32
+; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptosi <2 x double> poison to <2 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptosi <4 x double> poison to <4 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptosi <8 x double> poison to <8 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'fptosi_double_i32'
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptosi double undef to i32
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptosi <2 x double> undef to <2 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptosi <4 x double> undef to <4 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptosi <8 x double> undef to <8 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptosi double poison to i32
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptosi <2 x double> poison to <2 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptosi <4 x double> poison to <4 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptosi <8 x double> poison to <8 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I32 = fptosi double undef to i32
-  %V2I32 = fptosi <2 x double> undef to <2 x i32>
-  %V4I32 = fptosi <4 x double> undef to <4 x i32>
-  %V8I32 = fptosi <8 x double> undef to <8 x i32>
-  ret i32 undef
+  %I32 = fptosi double poison to i32
+  %V2I32 = fptosi <2 x double> poison to <2 x i32>
+  %V4I32 = fptosi <4 x double> poison to <4 x i32>
+  %V8I32 = fptosi <8 x double> poison to <8 x i32>
+  ret i32 poison
 }
 
 define i32 @fptosi_double_i16(i32 %arg) {
 ; FAST-LABEL: 'fptosi_double_i16'
-; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi double undef to i16
-; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptosi <2 x double> undef to <2 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptosi <4 x double> undef to <4 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptosi <8 x double> undef to <8 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi double poison to i16
+; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptosi <2 x double> poison to <2 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptosi <4 x double> poison to <4 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptosi <8 x double> poison to <8 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; SLOW-LABEL: 'fptosi_double_i16'
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi double undef to i16
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptosi <2 x double> undef to <2 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptosi <4 x double> undef to <4 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptosi <8 x double> undef to <8 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi double poison to i16
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptosi <2 x double> poison to <2 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptosi <4 x double> poison to <4 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptosi <8 x double> poison to <8 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; FAST-SIZE-LABEL: 'fptosi_double_i16'
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi double undef to i16
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptosi <2 x double> undef to <2 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptosi <4 x double> undef to <4 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptosi <8 x double> undef to <8 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi double poison to i16
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptosi <2 x double> poison to <2 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptosi <4 x double> poison to <4 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptosi <8 x double> poison to <8 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
 ; SLOW-SIZE-LABEL: 'fptosi_double_i16'
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi double undef to i16
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptosi <2 x double> undef to <2 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptosi <4 x double> undef to <4 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptosi <8 x double> undef to <8 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi double poison to i16
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptosi <2 x double> poison to <2 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptosi <4 x double> poison to <4 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptosi <8 x double> poison to <8 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I16 = fptosi double undef to i16
-  %V2I16 = fptosi <2 x double> undef to <2 x i16>
-  %V4I16 = fptosi <4 x double> undef to <4 x i16>
-  %V8I16 = fptosi <8 x double> undef to <8 x i16>
-  ret i32 undef
+  %I16 = fptosi double poison to i16
+  %V2I16 = fptosi <2 x double> poison to <2 x i16>
+  %V4I16 = fptosi <4 x double> poison to <4 x i16>
+  %V8I16 = fptosi <8 x double> poison to <8 x i16>
+  ret i32 poison
 }
 
 define i32 @fptosi_double_i8(i32 %arg) {
 ; FAST-LABEL: 'fptosi_double_i8'
-; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi double undef to i8
-; FAST-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptosi <2 x double> undef to <2 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptosi <4 x double> undef to <4 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptosi <8 x double> undef to <8 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi double poison to i8
+; FAST-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptosi <2 x double> poison to <2 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptosi <4 x double> poison to <4 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptosi <8 x double> poison to <8 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; SLOW-LABEL: 'fptosi_double_i8'
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi double undef to i8
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptosi <2 x double> undef to <2 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptosi <4 x double> undef to <4 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptosi <8 x double> undef to <8 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi double poison to i8
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptosi <2 x double> poison to <2 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptosi <4 x double> poison to <4 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptosi <8 x double> poison to <8 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; FAST-SIZE-LABEL: 'fptosi_double_i8'
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi double undef to i8
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptosi <2 x double> undef to <2 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptosi <4 x double> undef to <4 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptosi <8 x double> undef to <8 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi double poison to i8
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptosi <2 x double> poison to <2 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptosi <4 x double> poison to <4 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptosi <8 x double> poison to <8 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
 ; SLOW-SIZE-LABEL: 'fptosi_double_i8'
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi double undef to i8
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptosi <2 x double> undef to <2 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptosi <4 x double> undef to <4 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptosi <8 x double> undef to <8 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi double poison to i8
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptosi <2 x double> poison to <2 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptosi <4 x double> poison to <4 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptosi <8 x double> poison to <8 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I8 = fptosi double undef to i8
-  %V2I8 = fptosi <2 x double> undef to <2 x i8>
-  %V4I8 = fptosi <4 x double> undef to <4 x i8>
-  %V8I8 = fptosi <8 x double> undef to <8 x i8>
-  ret i32 undef
+  %I8 = fptosi double poison to i8
+  %V2I8 = fptosi <2 x double> poison to <2 x i8>
+  %V4I8 = fptosi <4 x double> poison to <4 x i8>
+  %V8I8 = fptosi <8 x double> poison to <8 x i8>
+  ret i32 poison
 }
 
 define i32 @fptosi_float_i64(i32 %arg) {
 ; ALL-LABEL: 'fptosi_float_i64'
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptosi float undef to i64
-; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptosi <2 x float> undef to <2 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptosi <4 x float> undef to <4 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptosi <8 x float> undef to <8 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I64 = fptosi <16 x float> undef to <16 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptosi float poison to i64
+; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptosi <2 x float> poison to <2 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptosi <4 x float> poison to <4 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptosi <8 x float> poison to <8 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I64 = fptosi <16 x float> poison to <16 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'fptosi_float_i64'
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptosi float undef to i64
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptosi <2 x float> undef to <2 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptosi <4 x float> undef to <4 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptosi <8 x float> undef to <8 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I64 = fptosi <16 x float> undef to <16 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptosi float poison to i64
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptosi <2 x float> poison to <2 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptosi <4 x float> poison to <4 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptosi <8 x float> poison to <8 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I64 = fptosi <16 x float> poison to <16 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I64 = fptosi float undef to i64
-  %V2I64 = fptosi <2 x float> undef to <2 x i64>
-  %V4I64 = fptosi <4 x float> undef to <4 x i64>
-  %V8I64 = fptosi <8 x float> undef to <8 x i64>
-  %V16I64 = fptosi <16 x float> undef to <16 x i64>
-  ret i32 undef
+  %I64 = fptosi float poison to i64
+  %V2I64 = fptosi <2 x float> poison to <2 x i64>
+  %V4I64 = fptosi <4 x float> poison to <4 x i64>
+  %V8I64 = fptosi <8 x float> poison to <8 x i64>
+  %V16I64 = fptosi <16 x float> poison to <16 x i64>
+  ret i32 poison
 }
 
 define i32 @fptosi_float_i32(i32 %arg) {
 ; ALL-LABEL: 'fptosi_float_i32'
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptosi float undef to i32
-; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptosi <2 x float> undef to <2 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptosi <4 x float> undef to <4 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptosi <8 x float> undef to <8 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I32 = fptosi <16 x float> undef to <16 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptosi float poison to i32
+; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptosi <2 x float> poison to <2 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptosi <4 x float> poison to <4 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptosi <8 x float> poison to <8 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I32 = fptosi <16 x float> poison to <16 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'fptosi_float_i32'
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptosi float undef to i32
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptosi <2 x float> undef to <2 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptosi <4 x float> undef to <4 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptosi <8 x float> undef to <8 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I32 = fptosi <16 x float> undef to <16 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptosi float poison to i32
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptosi <2 x float> poison to <2 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptosi <4 x float> poison to <4 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptosi <8 x float> poison to <8 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I32 = fptosi <16 x float> poison to <16 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I32 = fptosi float undef to i32
-  %V2I32 = fptosi <2 x float> undef to <2 x i32>
-  %V4I32 = fptosi <4 x float> undef to <4 x i32>
-  %V8I32 = fptosi <8 x float> undef to <8 x i32>
-  %V16I32 = fptosi <16 x float> undef to <16 x i32>
-  ret i32 undef
+  %I32 = fptosi float poison to i32
+  %V2I32 = fptosi <2 x float> poison to <2 x i32>
+  %V4I32 = fptosi <4 x float> poison to <4 x i32>
+  %V8I32 = fptosi <8 x float> poison to <8 x i32>
+  %V16I32 = fptosi <16 x float> poison to <16 x i32>
+  ret i32 poison
 }
 
 define i32 @fptosi_float_i16(i32 %arg) {
 ; FAST-LABEL: 'fptosi_float_i16'
-; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi float undef to i16
-; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptosi <2 x float> undef to <2 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptosi <4 x float> undef to <4 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptosi <8 x float> undef to <8 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 46 for instruction: %V16I16 = fptosi <16 x float> undef to <16 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi float poison to i16
+; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptosi <2 x float> poison to <2 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptosi <4 x float> poison to <4 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptosi <8 x float> poison to <8 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 46 for instruction: %V16I16 = fptosi <16 x float> poison to <16 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; SLOW-LABEL: 'fptosi_float_i16'
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi float undef to i16
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptosi <2 x float> undef to <2 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptosi <4 x float> undef to <4 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptosi <8 x float> undef to <8 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I16 = fptosi <16 x float> undef to <16 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi float poison to i16
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptosi <2 x float> poison to <2 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptosi <4 x float> poison to <4 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptosi <8 x float> poison to <8 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I16 = fptosi <16 x float> poison to <16 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; FAST-SIZE-LABEL: 'fptosi_float_i16'
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi float undef to i16
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptosi <2 x float> undef to <2 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptosi <4 x float> undef to <4 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptosi <8 x float> undef to <8 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 46 for instruction: %V16I16 = fptosi <16 x float> undef to <16 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi float poison to i16
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptosi <2 x float> poison to <2 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptosi <4 x float> poison to <4 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptosi <8 x float> poison to <8 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 46 for instruction: %V16I16 = fptosi <16 x float> poison to <16 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
 ; SLOW-SIZE-LABEL: 'fptosi_float_i16'
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi float undef to i16
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptosi <2 x float> undef to <2 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptosi <4 x float> undef to <4 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptosi <8 x float> undef to <8 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I16 = fptosi <16 x float> undef to <16 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptosi float poison to i16
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptosi <2 x float> poison to <2 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptosi <4 x float> poison to <4 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptosi <8 x float> poison to <8 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I16 = fptosi <16 x float> poison to <16 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I16 = fptosi float undef to i16
-  %V2I16 = fptosi <2 x float> undef to <2 x i16>
-  %V4I16 = fptosi <4 x float> undef to <4 x i16>
-  %V8I16 = fptosi <8 x float> undef to <8 x i16>
-  %V16I16 = fptosi <16 x float> undef to <16 x i16>
-  ret i32 undef
+  %I16 = fptosi float poison to i16
+  %V2I16 = fptosi <2 x float> poison to <2 x i16>
+  %V4I16 = fptosi <4 x float> poison to <4 x i16>
+  %V8I16 = fptosi <8 x float> poison to <8 x i16>
+  %V16I16 = fptosi <16 x float> poison to <16 x i16>
+  ret i32 poison
 }
 
 define i32 @fptosi_float_i8(i32 %arg) {
 ; FAST-LABEL: 'fptosi_float_i8'
-; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi float undef to i8
-; FAST-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptosi <2 x float> undef to <2 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptosi <4 x float> undef to <4 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptosi <8 x float> undef to <8 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 48 for instruction: %V16I8 = fptosi <16 x float> undef to <16 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi float poison to i8
+; FAST-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptosi <2 x float> poison to <2 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptosi <4 x float> poison to <4 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptosi <8 x float> poison to <8 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 48 for instruction: %V16I8 = fptosi <16 x float> poison to <16 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; SLOW-LABEL: 'fptosi_float_i8'
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi float undef to i8
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptosi <2 x float> undef to <2 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptosi <4 x float> undef to <4 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptosi <8 x float> undef to <8 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I8 = fptosi <16 x float> undef to <16 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi float poison to i8
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptosi <2 x float> poison to <2 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptosi <4 x float> poison to <4 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptosi <8 x float> poison to <8 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I8 = fptosi <16 x float> poison to <16 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; FAST-SIZE-LABEL: 'fptosi_float_i8'
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi float undef to i8
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptosi <2 x float> undef to <2 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptosi <4 x float> undef to <4 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptosi <8 x float> undef to <8 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 48 for instruction: %V16I8 = fptosi <16 x float> undef to <16 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi float poison to i8
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptosi <2 x float> poison to <2 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptosi <4 x float> poison to <4 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptosi <8 x float> poison to <8 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 48 for instruction: %V16I8 = fptosi <16 x float> poison to <16 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
 ; SLOW-SIZE-LABEL: 'fptosi_float_i8'
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi float undef to i8
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptosi <2 x float> undef to <2 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptosi <4 x float> undef to <4 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptosi <8 x float> undef to <8 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I8 = fptosi <16 x float> undef to <16 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptosi float poison to i8
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptosi <2 x float> poison to <2 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptosi <4 x float> poison to <4 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptosi <8 x float> poison to <8 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I8 = fptosi <16 x float> poison to <16 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I8 = fptosi float undef to i8
-  %V2I8 = fptosi <2 x float> undef to <2 x i8>
-  %V4I8 = fptosi <4 x float> undef to <4 x i8>
-  %V8I8 = fptosi <8 x float> undef to <8 x i8>
-  %V16I8 = fptosi <16 x float> undef to <16 x i8>
-  ret i32 undef
+  %I8 = fptosi float poison to i8
+  %V2I8 = fptosi <2 x float> poison to <2 x i8>
+  %V4I8 = fptosi <4 x float> poison to <4 x i8>
+  %V8I8 = fptosi <8 x float> poison to <8 x i8>
+  %V16I8 = fptosi <16 x float> poison to <16 x i8>
+  ret i32 poison
 }

diff  --git a/llvm/test/Analysis/CostModel/AMDGPU/fptoui.ll b/llvm/test/Analysis/CostModel/AMDGPU/fptoui.ll
index 9a29d520a2417..ae5915c63fac5 100644
--- a/llvm/test/Analysis/CostModel/AMDGPU/fptoui.ll
+++ b/llvm/test/Analysis/CostModel/AMDGPU/fptoui.ll
@@ -12,248 +12,248 @@
 
 define i32 @fptoui_double_i64(i32 %arg) {
 ; ALL-LABEL: 'fptoui_double_i64'
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptoui double undef to i64
-; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptoui <2 x double> undef to <2 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptoui <4 x double> undef to <4 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptoui <8 x double> undef to <8 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptoui double poison to i64
+; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptoui <2 x double> poison to <2 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptoui <4 x double> poison to <4 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptoui <8 x double> poison to <8 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'fptoui_double_i64'
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptoui double undef to i64
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptoui <2 x double> undef to <2 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptoui <4 x double> undef to <4 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptoui <8 x double> undef to <8 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptoui double poison to i64
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptoui <2 x double> poison to <2 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptoui <4 x double> poison to <4 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptoui <8 x double> poison to <8 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I64 = fptoui double undef to i64
-  %V2I64 = fptoui <2 x double> undef to <2 x i64>
-  %V4I64 = fptoui <4 x double> undef to <4 x i64>
-  %V8I64 = fptoui <8 x double> undef to <8 x i64>
-  ret i32 undef
+  %I64 = fptoui double poison to i64
+  %V2I64 = fptoui <2 x double> poison to <2 x i64>
+  %V4I64 = fptoui <4 x double> poison to <4 x i64>
+  %V8I64 = fptoui <8 x double> poison to <8 x i64>
+  ret i32 poison
 }
 
 define i32 @fptoui_double_i32(i32 %arg) {
 ; ALL-LABEL: 'fptoui_double_i32'
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptoui double undef to i32
-; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptoui <2 x double> undef to <2 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptoui <4 x double> undef to <4 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptoui <8 x double> undef to <8 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptoui double poison to i32
+; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptoui <2 x double> poison to <2 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptoui <4 x double> poison to <4 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptoui <8 x double> poison to <8 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'fptoui_double_i32'
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptoui double undef to i32
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptoui <2 x double> undef to <2 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptoui <4 x double> undef to <4 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptoui <8 x double> undef to <8 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptoui double poison to i32
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptoui <2 x double> poison to <2 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptoui <4 x double> poison to <4 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptoui <8 x double> poison to <8 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I32 = fptoui double undef to i32
-  %V2I32 = fptoui <2 x double> undef to <2 x i32>
-  %V4I32 = fptoui <4 x double> undef to <4 x i32>
-  %V8I32 = fptoui <8 x double> undef to <8 x i32>
-  ret i32 undef
+  %I32 = fptoui double poison to i32
+  %V2I32 = fptoui <2 x double> poison to <2 x i32>
+  %V4I32 = fptoui <4 x double> poison to <4 x i32>
+  %V8I32 = fptoui <8 x double> poison to <8 x i32>
+  ret i32 poison
 }
 
 define i32 @fptoui_double_i16(i32 %arg) {
 ; FAST-LABEL: 'fptoui_double_i16'
-; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui double undef to i16
-; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptoui <2 x double> undef to <2 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptoui <4 x double> undef to <4 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptoui <8 x double> undef to <8 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui double poison to i16
+; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptoui <2 x double> poison to <2 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptoui <4 x double> poison to <4 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptoui <8 x double> poison to <8 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; SLOW-LABEL: 'fptoui_double_i16'
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui double undef to i16
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptoui <2 x double> undef to <2 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptoui <4 x double> undef to <4 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptoui <8 x double> undef to <8 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui double poison to i16
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptoui <2 x double> poison to <2 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptoui <4 x double> poison to <4 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptoui <8 x double> poison to <8 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; FAST-SIZE-LABEL: 'fptoui_double_i16'
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui double undef to i16
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptoui <2 x double> undef to <2 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptoui <4 x double> undef to <4 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptoui <8 x double> undef to <8 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui double poison to i16
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptoui <2 x double> poison to <2 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptoui <4 x double> poison to <4 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptoui <8 x double> poison to <8 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
 ; SLOW-SIZE-LABEL: 'fptoui_double_i16'
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui double undef to i16
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptoui <2 x double> undef to <2 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptoui <4 x double> undef to <4 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptoui <8 x double> undef to <8 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui double poison to i16
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptoui <2 x double> poison to <2 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptoui <4 x double> poison to <4 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptoui <8 x double> poison to <8 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I16 = fptoui double undef to i16
-  %V2I16 = fptoui <2 x double> undef to <2 x i16>
-  %V4I16 = fptoui <4 x double> undef to <4 x i16>
-  %V8I16 = fptoui <8 x double> undef to <8 x i16>
-  ret i32 undef
+  %I16 = fptoui double poison to i16
+  %V2I16 = fptoui <2 x double> poison to <2 x i16>
+  %V4I16 = fptoui <4 x double> poison to <4 x i16>
+  %V8I16 = fptoui <8 x double> poison to <8 x i16>
+  ret i32 poison
 }
 
 define i32 @fptoui_double_i8(i32 %arg) {
 ; FAST-LABEL: 'fptoui_double_i8'
-; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui double undef to i8
-; FAST-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptoui <2 x double> undef to <2 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptoui <4 x double> undef to <4 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptoui <8 x double> undef to <8 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui double poison to i8
+; FAST-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptoui <2 x double> poison to <2 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptoui <4 x double> poison to <4 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptoui <8 x double> poison to <8 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; SLOW-LABEL: 'fptoui_double_i8'
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui double undef to i8
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptoui <2 x double> undef to <2 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptoui <4 x double> undef to <4 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptoui <8 x double> undef to <8 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui double poison to i8
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptoui <2 x double> poison to <2 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptoui <4 x double> poison to <4 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptoui <8 x double> poison to <8 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; FAST-SIZE-LABEL: 'fptoui_double_i8'
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui double undef to i8
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptoui <2 x double> undef to <2 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptoui <4 x double> undef to <4 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptoui <8 x double> undef to <8 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui double poison to i8
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptoui <2 x double> poison to <2 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptoui <4 x double> poison to <4 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptoui <8 x double> poison to <8 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
 ; SLOW-SIZE-LABEL: 'fptoui_double_i8'
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui double undef to i8
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptoui <2 x double> undef to <2 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptoui <4 x double> undef to <4 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptoui <8 x double> undef to <8 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui double poison to i8
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptoui <2 x double> poison to <2 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptoui <4 x double> poison to <4 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptoui <8 x double> poison to <8 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I8 = fptoui double undef to i8
-  %V2I8 = fptoui <2 x double> undef to <2 x i8>
-  %V4I8 = fptoui <4 x double> undef to <4 x i8>
-  %V8I8 = fptoui <8 x double> undef to <8 x i8>
-  ret i32 undef
+  %I8 = fptoui double poison to i8
+  %V2I8 = fptoui <2 x double> poison to <2 x i8>
+  %V4I8 = fptoui <4 x double> poison to <4 x i8>
+  %V8I8 = fptoui <8 x double> poison to <8 x i8>
+  ret i32 poison
 }
 
 define i32 @fptoui_float_i64(i32 %arg) {
 ; ALL-LABEL: 'fptoui_float_i64'
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptoui float undef to i64
-; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptoui <2 x float> undef to <2 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptoui <4 x float> undef to <4 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptoui <8 x float> undef to <8 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I64 = fptoui <16 x float> undef to <16 x i64>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptoui float poison to i64
+; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptoui <2 x float> poison to <2 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptoui <4 x float> poison to <4 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptoui <8 x float> poison to <8 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I64 = fptoui <16 x float> poison to <16 x i64>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'fptoui_float_i64'
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptoui float undef to i64
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptoui <2 x float> undef to <2 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptoui <4 x float> undef to <4 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptoui <8 x float> undef to <8 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I64 = fptoui <16 x float> undef to <16 x i64>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I64 = fptoui float poison to i64
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I64 = fptoui <2 x float> poison to <2 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I64 = fptoui <4 x float> poison to <4 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I64 = fptoui <8 x float> poison to <8 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I64 = fptoui <16 x float> poison to <16 x i64>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I64 = fptoui float undef to i64
-  %V2I64 = fptoui <2 x float> undef to <2 x i64>
-  %V4I64 = fptoui <4 x float> undef to <4 x i64>
-  %V8I64 = fptoui <8 x float> undef to <8 x i64>
-  %V16I64 = fptoui <16 x float> undef to <16 x i64>
-  ret i32 undef
+  %I64 = fptoui float poison to i64
+  %V2I64 = fptoui <2 x float> poison to <2 x i64>
+  %V4I64 = fptoui <4 x float> poison to <4 x i64>
+  %V8I64 = fptoui <8 x float> poison to <8 x i64>
+  %V16I64 = fptoui <16 x float> poison to <16 x i64>
+  ret i32 poison
 }
 
 define i32 @fptoui_float_i32(i32 %arg) {
 ; ALL-LABEL: 'fptoui_float_i32'
-; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptoui float undef to i32
-; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptoui <2 x float> undef to <2 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptoui <4 x float> undef to <4 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptoui <8 x float> undef to <8 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I32 = fptoui <16 x float> undef to <16 x i32>
-; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; ALL-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptoui float poison to i32
+; ALL-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptoui <2 x float> poison to <2 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptoui <4 x float> poison to <4 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptoui <8 x float> poison to <8 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I32 = fptoui <16 x float> poison to <16 x i32>
+; ALL-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; ALL-SIZE-LABEL: 'fptoui_float_i32'
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptoui float undef to i32
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptoui <2 x float> undef to <2 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptoui <4 x float> undef to <4 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptoui <8 x float> undef to <8 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I32 = fptoui <16 x float> undef to <16 x i32>
-; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I32 = fptoui float poison to i32
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I32 = fptoui <2 x float> poison to <2 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I32 = fptoui <4 x float> poison to <4 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I32 = fptoui <8 x float> poison to <8 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I32 = fptoui <16 x float> poison to <16 x i32>
+; ALL-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I32 = fptoui float undef to i32
-  %V2I32 = fptoui <2 x float> undef to <2 x i32>
-  %V4I32 = fptoui <4 x float> undef to <4 x i32>
-  %V8I32 = fptoui <8 x float> undef to <8 x i32>
-  %V16I32 = fptoui <16 x float> undef to <16 x i32>
-  ret i32 undef
+  %I32 = fptoui float poison to i32
+  %V2I32 = fptoui <2 x float> poison to <2 x i32>
+  %V4I32 = fptoui <4 x float> poison to <4 x i32>
+  %V8I32 = fptoui <8 x float> poison to <8 x i32>
+  %V16I32 = fptoui <16 x float> poison to <16 x i32>
+  ret i32 poison
 }
 
 define i32 @fptoui_float_i16(i32 %arg) {
 ; FAST-LABEL: 'fptoui_float_i16'
-; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui float undef to i16
-; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptoui <2 x float> undef to <2 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptoui <4 x float> undef to <4 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptoui <8 x float> undef to <8 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 46 for instruction: %V16I16 = fptoui <16 x float> undef to <16 x i16>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui float poison to i16
+; FAST-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptoui <2 x float> poison to <2 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptoui <4 x float> poison to <4 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptoui <8 x float> poison to <8 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 46 for instruction: %V16I16 = fptoui <16 x float> poison to <16 x i16>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; SLOW-LABEL: 'fptoui_float_i16'
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui float undef to i16
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptoui <2 x float> undef to <2 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptoui <4 x float> undef to <4 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptoui <8 x float> undef to <8 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I16 = fptoui <16 x float> undef to <16 x i16>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui float poison to i16
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptoui <2 x float> poison to <2 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptoui <4 x float> poison to <4 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptoui <8 x float> poison to <8 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I16 = fptoui <16 x float> poison to <16 x i16>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; FAST-SIZE-LABEL: 'fptoui_float_i16'
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui float undef to i16
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptoui <2 x float> undef to <2 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptoui <4 x float> undef to <4 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptoui <8 x float> undef to <8 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 46 for instruction: %V16I16 = fptoui <16 x float> undef to <16 x i16>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui float poison to i16
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V2I16 = fptoui <2 x float> poison to <2 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %V4I16 = fptoui <4 x float> poison to <4 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 22 for instruction: %V8I16 = fptoui <8 x float> poison to <8 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 46 for instruction: %V16I16 = fptoui <16 x float> poison to <16 x i16>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
 ; SLOW-SIZE-LABEL: 'fptoui_float_i16'
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui float undef to i16
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptoui <2 x float> undef to <2 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptoui <4 x float> undef to <4 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptoui <8 x float> undef to <8 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I16 = fptoui <16 x float> undef to <16 x i16>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I16 = fptoui float poison to i16
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I16 = fptoui <2 x float> poison to <2 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I16 = fptoui <4 x float> poison to <4 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I16 = fptoui <8 x float> poison to <8 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I16 = fptoui <16 x float> poison to <16 x i16>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I16 = fptoui float undef to i16
-  %V2I16 = fptoui <2 x float> undef to <2 x i16>
-  %V4I16 = fptoui <4 x float> undef to <4 x i16>
-  %V8I16 = fptoui <8 x float> undef to <8 x i16>
-  %V16I16 = fptoui <16 x float> undef to <16 x i16>
-  ret i32 undef
+  %I16 = fptoui float poison to i16
+  %V2I16 = fptoui <2 x float> poison to <2 x i16>
+  %V4I16 = fptoui <4 x float> poison to <4 x i16>
+  %V8I16 = fptoui <8 x float> poison to <8 x i16>
+  %V16I16 = fptoui <16 x float> poison to <16 x i16>
+  ret i32 poison
 }
 
 define i32 @fptoui_float_i8(i32 %arg) {
 ; FAST-LABEL: 'fptoui_float_i8'
-; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui float undef to i8
-; FAST-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptoui <2 x float> undef to <2 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptoui <4 x float> undef to <4 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptoui <8 x float> undef to <8 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 48 for instruction: %V16I8 = fptoui <16 x float> undef to <16 x i8>
-; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; FAST-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui float poison to i8
+; FAST-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptoui <2 x float> poison to <2 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptoui <4 x float> poison to <4 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptoui <8 x float> poison to <8 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 48 for instruction: %V16I8 = fptoui <16 x float> poison to <16 x i8>
+; FAST-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; SLOW-LABEL: 'fptoui_float_i8'
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui float undef to i8
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptoui <2 x float> undef to <2 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptoui <4 x float> undef to <4 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptoui <8 x float> undef to <8 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I8 = fptoui <16 x float> undef to <16 x i8>
-; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 undef
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui float poison to i8
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptoui <2 x float> poison to <2 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptoui <4 x float> poison to <4 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptoui <8 x float> poison to <8 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I8 = fptoui <16 x float> poison to <16 x i8>
+; SLOW-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: ret i32 poison
 ;
 ; FAST-SIZE-LABEL: 'fptoui_float_i8'
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui float undef to i8
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptoui <2 x float> undef to <2 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptoui <4 x float> undef to <4 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptoui <8 x float> undef to <8 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 48 for instruction: %V16I8 = fptoui <16 x float> undef to <16 x i8>
-; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui float poison to i8
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %V2I8 = fptoui <2 x float> poison to <2 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 12 for instruction: %V4I8 = fptoui <4 x float> poison to <4 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 24 for instruction: %V8I8 = fptoui <8 x float> poison to <8 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 48 for instruction: %V16I8 = fptoui <16 x float> poison to <16 x i8>
+; FAST-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
 ; SLOW-SIZE-LABEL: 'fptoui_float_i8'
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui float undef to i8
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptoui <2 x float> undef to <2 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptoui <4 x float> undef to <4 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptoui <8 x float> undef to <8 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I8 = fptoui <16 x float> undef to <16 x i8>
-; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %I8 = fptoui float poison to i8
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %V2I8 = fptoui <2 x float> poison to <2 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %V4I8 = fptoui <4 x float> poison to <4 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %V8I8 = fptoui <8 x float> poison to <8 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %V16I8 = fptoui <16 x float> poison to <16 x i8>
+; SLOW-SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret i32 poison
 ;
-  %I8 = fptoui float undef to i8
-  %V2I8 = fptoui <2 x float> undef to <2 x i8>
-  %V4I8 = fptoui <4 x float> undef to <4 x i8>
-  %V8I8 = fptoui <8 x float> undef to <8 x i8>
-  %V16I8 = fptoui <16 x float> undef to <16 x i8>
-  ret i32 undef
+  %I8 = fptoui float poison to i8
+  %V2I8 = fptoui <2 x float> poison to <2 x i8>
+  %V4I8 = fptoui <4 x float> poison to <4 x i8>
+  %V8I8 = fptoui <8 x float> poison to <8 x i8>
+  %V16I8 = fptoui <16 x float> poison to <16 x i8>
+  ret i32 poison
 }


        


More information about the llvm-commits mailing list