[clang] [clang][RISCVVEmitter] Remove no-op ptr-to-ptr bitcast (NFC) (PR #74179)
Youngsuk Kim via cfe-commits
cfe-commits at lists.llvm.org
Fri Dec 1 20:15:27 PST 2023
https://github.com/JOE1994 created https://github.com/llvm/llvm-project/pull/74179
Remove ptr-to-ptr bitcast which was added back in 939352b6ec31db4e8defe07856868438fbc5340d . With opaque pointers, the bitcast is now redundant.
Opaque ptr cleanup effort.
>From 56eb182b28277cc6160e6916d98a02b1ee12fadb Mon Sep 17 00:00:00 2001
From: Youngsuk Kim <youngsuk.kim at hpe.com>
Date: Fri, 1 Dec 2023 21:59:59 -0600
Subject: [PATCH] [clang][RISCVVEmitter] Remove no-op ptr-to-ptr bitcast (NFC)
Remove ptr-to-ptr bitcast which was added back in 939352b6ec31db4e8defe07856868438fbc5340d .
With opaque pointers, the bitcast is now redundant.
Opaque ptr cleanup effort.
---
clang/utils/TableGen/RISCVVEmitter.cpp | 3 ---
1 file changed, 3 deletions(-)
diff --git a/clang/utils/TableGen/RISCVVEmitter.cpp b/clang/utils/TableGen/RISCVVEmitter.cpp
index cf731e8414a3b83..1fb41805a0473dd 100644
--- a/clang/utils/TableGen/RISCVVEmitter.cpp
+++ b/clang/utils/TableGen/RISCVVEmitter.cpp
@@ -180,13 +180,10 @@ void emitCodeGenSwitchBody(const RVVIntrinsic *RVVI, raw_ostream &OS) {
return;
}
- // Cast pointer operand of vector load intrinsic.
for (const auto &I : enumerate(RVVI->getInputTypes())) {
if (I.value()->isPointer()) {
assert(RVVI->getIntrinsicTypes().front() == -1 &&
"RVVI should be vector load intrinsic.");
- OS << " Ops[" << I.index() << "] = Builder.CreateBitCast(Ops[";
- OS << I.index() << "], ResultType->getPointerTo());\n";
}
}
More information about the cfe-commits
mailing list