[llvm] 135f6a1 - [libomptarget][plugin-nextgen] fix for [TypePromotion] NewPM support.
Arsenault, Matthew via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 3 09:11:58 PST 2023
[AMD Official Use Only - General]
I don't see how the printf change is relevant here, but you ended up reproducing part of https://reviews.llvm.org/D140560 which should be separate
AMDGPU: Fix broken opaque pointer handling in printf pass<https://reviews.llvm.org/D140560>
AMDGPU: Fix broken opaque pointer handling in printf pass. Needs Review Public. Actions
reviews.llvm.org
________________________________
From: llvm-commits <llvm-commits-bounces at lists.llvm.org> on behalf of Ron Lieberman via llvm-commits <llvm-commits at lists.llvm.org>
Sent: Tuesday, January 3, 2023 12:04 PM
To: llvm-commits at lists.llvm.org <llvm-commits at lists.llvm.org>
Subject: [llvm] 135f6a1 - [libomptarget][plugin-nextgen] fix for [TypePromotion] NewPM support.
Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
Author: Ron Lieberman
Date: 2023-01-03T11:04:13-06:00
New Revision: 135f6a1ee8b20bb392ebad2fa5aef78e3a30ddb4
URL: https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fllvm%2Fllvm-project%2Fcommit%2F135f6a1ee8b20bb392ebad2fa5aef78e3a30ddb4&data=05%7C01%7CMatthew.Arsenault%40amd.com%7Cf1de6b81a1554d6d75b008daedac9861%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638083622816213549%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=MV5lxKqJ1JHzqeJeSv%2F9bIHIBcj%2BtLGxryhc0jbX8tE%3D&reserved=0
DIFF: https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fllvm%2Fllvm-project%2Fcommit%2F135f6a1ee8b20bb392ebad2fa5aef78e3a30ddb4.diff&data=05%7C01%7CMatthew.Arsenault%40amd.com%7Cf1de6b81a1554d6d75b008daedac9861%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638083622816369766%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=IBGljw9a700Pb%2BEKz6YOAM9MGbwnDpyO7JW8V5nH8AM%3D&reserved=0
LOG: [libomptarget][plugin-nextgen] fix for [TypePromotion] NewPM support.
Added:
Modified:
llvm/lib/Target/AMDGPU/AMDGPUPrintfRuntimeBinding.cpp
openmp/libomptarget/plugins-nextgen/common/PluginInterface/JIT.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/AMDGPU/AMDGPUPrintfRuntimeBinding.cpp b/llvm/lib/Target/AMDGPU/AMDGPUPrintfRuntimeBinding.cpp
index 92fd7bc87716a..2775d0621b10e 100644
--- a/llvm/lib/Target/AMDGPU/AMDGPUPrintfRuntimeBinding.cpp
+++ b/llvm/lib/Target/AMDGPU/AMDGPUPrintfRuntimeBinding.cpp
@@ -133,16 +133,7 @@ void AMDGPUPrintfRuntimeBindingImpl::getConversionSpecifiers(
bool AMDGPUPrintfRuntimeBindingImpl::shouldPrintAsStr(char Specifier,
Type *OpType) const {
- if (Specifier != 's')
- return false;
- const PointerType *PT = dyn_cast<PointerType>(OpType);
- if (!PT || PT->getAddressSpace() != AMDGPUAS::CONSTANT_ADDRESS)
- return false;
- Type *ElemType = PT->getContainedType(0);
- if (ElemType->getTypeID() != Type::IntegerTyID)
- return false;
- IntegerType *ElemIType = cast<IntegerType>(ElemType);
- return ElemIType->getBitWidth() == 8;
+ return Specifier == 's' && isa<PointerType>(OpType);
}
bool AMDGPUPrintfRuntimeBindingImpl::lowerPrintfForGpu(Module &M) {
diff --git a/openmp/libomptarget/plugins-nextgen/common/PluginInterface/JIT.cpp b/openmp/libomptarget/plugins-nextgen/common/PluginInterface/JIT.cpp
index 7cc1bb88cd004..893f4b17f3921 100644
--- a/openmp/libomptarget/plugins-nextgen/common/PluginInterface/JIT.cpp
+++ b/openmp/libomptarget/plugins-nextgen/common/PluginInterface/JIT.cpp
@@ -107,7 +107,7 @@ void init(Triple TT) {
initializeWasmEHPreparePass(Registry);
initializeWriteBitcodePassPass(Registry);
initializeHardwareLoopsPass(Registry);
- initializeTypePromotionPass(Registry);
+ initializeTypePromotionLegacyPass(Registry);
initializeReplaceWithVeclibLegacyPass(Registry);
initializeJMCInstrumenterPass(Registry);
}
_______________________________________________
llvm-commits mailing list
llvm-commits at lists.llvm.org
https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.llvm.org%2Fcgi-bin%2Fmailman%2Flistinfo%2Fllvm-commits&data=05%7C01%7CMatthew.Arsenault%40amd.com%7Cf1de6b81a1554d6d75b008daedac9861%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638083622816369766%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=uDvs5ii5Ki82Hpk0elbCGAS1hvLrQNw3%2BuddpO00i1U%3D&reserved=0
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230103/054f4e84/attachment.html>
More information about the llvm-commits
mailing list