[polly][GPGPU] Fixup related to overloading exponent type in llvm.powi

Commit 4c7f820b2b206bb changed the llvm.powi intrinsic to support
different 'int' sizes for the exponent. That happened to break
the IntrinsicToLibdeviceFunc mapping in PPCGCodeGeneration, which
obviously should have been updated as part of commit 4c7f820b2b
(https://reviews.llvm.org/D99439).

The shortcoming was found by buildbots that use
   -DPOLLY_ENABLE_GPGPU_CODEGEN=ON

This patch should fixup the problem.

GitOrigin-RevId: 6aac2773d80b42bcf9da2414bbd410aa9f10095e
diff --git a/lib/CodeGen/PPCGCodeGeneration.cpp b/lib/CodeGen/PPCGCodeGeneration.cpp
index 39f320a..dac1fcd 100644
--- a/lib/CodeGen/PPCGCodeGeneration.cpp
+++ b/lib/CodeGen/PPCGCodeGeneration.cpp
@@ -1415,8 +1415,8 @@
 const std::map<std::string, std::string> IntrinsicToLibdeviceFunc = {
     {"llvm.exp.f64", "exp"},
     {"llvm.exp.f32", "expf"},
-    {"llvm.powi.f64", "powi"},
-    {"llvm.powi.f32", "powif"}};
+    {"llvm.powi.f64.i32", "powi"},
+    {"llvm.powi.f32.i32", "powif"}};
 
 /// Return the corresponding CUDA libdevice function name @p Name.
 /// Note that this function will try to convert instrinsics in the list
diff --git a/test/GPGPU/libdevice-functions-copied-into-kernel.ll b/test/GPGPU/libdevice-functions-copied-into-kernel.ll
index 62fc6ba..194cb6c 100644
--- a/test/GPGPU/libdevice-functions-copied-into-kernel.ll
+++ b/test/GPGPU/libdevice-functions-copied-into-kernel.ll
@@ -65,7 +65,7 @@
   %expf = tail call float @expf(float %A.arr.i.val)
   %cosf = tail call float @cosf(float %expf)
   %logf = tail call float @logf(float %cosf)
-  %powi = tail call float @llvm.powi.f32(float %logf, i32 2)
+  %powi = tail call float @llvm.powi.f32.i32(float %logf, i32 2)
   %exp = tail call float @llvm.exp.f32(float %powi)
   %B.arr.i = getelementptr inbounds float, float* %B, i64 %indvars.iv
   store float %exp, float* %B.arr.i, align 4
@@ -86,7 +86,7 @@
 declare float @expf(float) #0
 declare float @cosf(float) #0
 declare float @logf(float) #0
-declare float @llvm.powi.f32(float, i32) #0
+declare float @llvm.powi.f32.i32(float, i32) #0
 declare float @llvm.exp.f32(float) #0
 
 attributes #0 = { nounwind readnone }