Skip to content

Commit d49af43

Browse files
committed
Remove bitcasts and kmpc_MicroTy
1 parent c536935 commit d49af43

File tree

2 files changed

+2
-9
lines changed

2 files changed

+2
-9
lines changed

clang/lib/CodeGen/CGOpenMPRuntime.cpp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1475,10 +1475,6 @@ llvm::Type *CGOpenMPRuntime::getIdentTyPointerTy() {
14751475
return OMPBuilder.IdentPtr;
14761476
}
14771477

1478-
llvm::Type *CGOpenMPRuntime::getKmpc_MicroPointerTy() {
1479-
return llvm::PointerType::getUnqual(CGM.getLLVMContext());
1480-
}
1481-
14821478
static llvm::OffloadEntriesInfoManager::OMPTargetDeviceClauseKind
14831479
convertDeviceClause(const VarDecl *VD) {
14841480
std::optional<OMPDeclareTargetDeclAttr::DevTypeTy> DevTy =
@@ -1855,7 +1851,7 @@ void CGOpenMPRuntime::emitParallelCall(CodeGenFunction &CGF, SourceLocation Loc,
18551851
llvm::Value *Args[] = {
18561852
RTLoc,
18571853
CGF.Builder.getInt32(CapturedVars.size()), // Number of captured vars
1858-
CGF.Builder.CreateBitCast(OutlinedFn, RT.getKmpc_MicroPointerTy())};
1854+
OutlinedFn};
18591855
llvm::SmallVector<llvm::Value *, 16> RealArgs;
18601856
RealArgs.append(std::begin(Args), std::end(Args));
18611857
RealArgs.append(CapturedVars.begin(), CapturedVars.end());
@@ -9931,7 +9927,7 @@ void CGOpenMPRuntime::emitTeamsCall(CodeGenFunction &CGF,
99319927
llvm::Value *Args[] = {
99329928
RTLoc,
99339929
CGF.Builder.getInt32(CapturedVars.size()), // Number of captured vars
9934-
CGF.Builder.CreateBitCast(OutlinedFn, getKmpc_MicroPointerTy())};
9930+
OutlinedFn};
99359931
llvm::SmallVector<llvm::Value *, 16> RealArgs;
99369932
RealArgs.append(std::begin(Args), std::end(Args));
99379933
RealArgs.append(CapturedVars.begin(), CapturedVars.end());

clang/lib/CodeGen/CGOpenMPRuntime.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -526,9 +526,6 @@ class CGOpenMPRuntime {
526526
/// Build type kmp_routine_entry_t (if not built yet).
527527
void emitKmpRoutineEntryT(QualType KmpInt32Ty);
528528

529-
/// Returns pointer to kmpc_micro type.
530-
llvm::Type *getKmpc_MicroPointerTy();
531-
532529
/// If the specified mangled name is not in the module, create and
533530
/// return threadprivate cache object. This object is a pointer's worth of
534531
/// storage that's reserved for use by the OpenMP runtime.

0 commit comments

Comments
 (0)