[PATCH] D145717: [llvm-c] Remove typed pointer APIs
Arthur Eubanks via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 9 13:36:26 PST 2023
aeubanks updated this revision to Diff 503919.
aeubanks added a comment.
only touch LLVMGetElementType
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D145717/new/
https://reviews.llvm.org/D145717
Files:
llvm/docs/ReleaseNotes.rst
llvm/include/llvm-c/Core.h
llvm/lib/IR/Core.cpp
Index: llvm/lib/IR/Core.cpp
===================================================================
--- llvm/lib/IR/Core.cpp
+++ llvm/lib/IR/Core.cpp
@@ -811,8 +811,6 @@
LLVMTypeRef LLVMGetElementType(LLVMTypeRef WrappedTy) {
auto *Ty = unwrap(WrappedTy);
- if (auto *PTy = dyn_cast<PointerType>(Ty))
- return wrap(PTy->getNonOpaquePointerElementType());
if (auto *ATy = dyn_cast<ArrayType>(Ty))
return wrap(ATy->getElementType());
return wrap(cast<VectorType>(Ty)->getElementType());
Index: llvm/include/llvm-c/Core.h
===================================================================
--- llvm/include/llvm-c/Core.h
+++ llvm/include/llvm-c/Core.h
@@ -1411,8 +1411,6 @@
/**
* Obtain the element type of an array or vector type.
*
- * This currently also works for pointer types, but this usage is deprecated.
- *
* @see llvm::SequentialType::getElementType()
*/
LLVMTypeRef LLVMGetElementType(LLVMTypeRef Ty);
Index: llvm/docs/ReleaseNotes.rst
===================================================================
--- llvm/docs/ReleaseNotes.rst
+++ llvm/docs/ReleaseNotes.rst
@@ -149,6 +149,8 @@
have been removed.
* Removed ``LLVMPassManagerBuilderRef`` and functions interacting with it.
These belonged to the no longer supported legacy pass manager.
+* As part of the opaque pointer transition, ``LLVMGetElementType`` no longer
+ gives the pointee type of a pointer type.
Changes to the FastISel infrastructure
--------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D145717.503919.patch
Type: text/x-patch
Size: 1491 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230309/4d7308da/attachment.bin>
More information about the llvm-commits
mailing list