[Polly] Remove some bitcasts (NFC)

No longer relevant with opaque pointers.

GitOrigin-RevId: 18680a36aa1b125cbde3fa0a10fa53db2b697f3a
diff --git a/lib/CodeGen/IslExprBuilder.cpp b/lib/CodeGen/IslExprBuilder.cpp
index 12b724c..f40511e 100644
--- a/lib/CodeGen/IslExprBuilder.cpp
+++ b/lib/CodeGen/IslExprBuilder.cpp
@@ -271,13 +271,6 @@
   assert(Base->getType()->isPointerTy() && "Access base should be a pointer");
   StringRef BaseName = Base->getName();
 
-  auto PointerTy = PointerType::get(SAI->getElementType(),
-                                    Base->getType()->getPointerAddressSpace());
-  if (Base->getType() != PointerTy) {
-    Base =
-        Builder.CreateBitCast(Base, PointerTy, "polly.access.cast." + BaseName);
-  }
-
   if (isl_ast_expr_get_op_n_arg(Expr) == 1) {
     isl_ast_expr_free(Expr);
     if (PollyDebugPrinting)
diff --git a/lib/CodeGen/LoopGenerators.cpp b/lib/CodeGen/LoopGenerators.cpp
index ebd4b22..5c99515 100644
--- a/lib/CodeGen/LoopGenerators.cpp
+++ b/lib/CodeGen/LoopGenerators.cpp
@@ -186,15 +186,12 @@
   *LoopBody = Builder.GetInsertPoint();
   Builder.SetInsertPoint(&*BeforeLoop);
 
-  Value *SubFnParam = Builder.CreateBitCast(Struct, Builder.getInt8PtrTy(),
-                                            "polly.par.userContext");
-
   // Add one as the upper bound provided by OpenMP is a < comparison
   // whereas the codegenForSequential function creates a <= comparison.
   UB = Builder.CreateAdd(UB, ConstantInt::get(LongType, 1));
 
   // Execute the prepared subfunction in parallel.
-  deployParallelExecution(SubFn, SubFnParam, LB, UB, Stride);
+  deployParallelExecution(SubFn, Struct, LB, UB, Stride);
 
   return IV;
 }
diff --git a/lib/CodeGen/LoopGeneratorsGOMP.cpp b/lib/CodeGen/LoopGeneratorsGOMP.cpp
index 1013f12..254c5e9 100644
--- a/lib/CodeGen/LoopGeneratorsGOMP.cpp
+++ b/lib/CodeGen/LoopGeneratorsGOMP.cpp
@@ -128,8 +128,7 @@
   Builder.SetInsertPoint(HeaderBB);
   Value *LBPtr = Builder.CreateAlloca(LongType, nullptr, "polly.par.LBPtr");
   Value *UBPtr = Builder.CreateAlloca(LongType, nullptr, "polly.par.UBPtr");
-  Value *UserContext = Builder.CreateBitCast(
-      &*SubFn->arg_begin(), StructData->getType(), "polly.par.userContext");
+  Value *UserContext = &*SubFn->arg_begin();
 
   extractValuesFromStruct(Data, StructData->getAllocatedType(), UserContext,
                           Map);
diff --git a/lib/CodeGen/LoopGeneratorsKMP.cpp b/lib/CodeGen/LoopGeneratorsKMP.cpp
index 5244e89..5bcfa66 100644
--- a/lib/CodeGen/LoopGeneratorsKMP.cpp
+++ b/lib/CodeGen/LoopGeneratorsKMP.cpp
@@ -175,11 +175,7 @@
   std::advance(AI, 1);
   Value *Shared = &*AI;
 
-  Value *UserContext = Builder.CreateBitCast(Shared, StructData->getType(),
-                                             "polly.par.userContext");
-
-  extractValuesFromStruct(Data, StructData->getAllocatedType(), UserContext,
-                          Map);
+  extractValuesFromStruct(Data, StructData->getAllocatedType(), Shared, Map);
 
   const auto Alignment = llvm::Align(is64BitArch() ? 8 : 4);
   Value *ID = Builder.CreateAlignedLoad(Builder.getInt32Ty(), IDPtr, Alignment,