[PATCH] D101704: [IR] Introduce the opaque pointer type

Arthur Eubanks via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat May 1 19:29:22 PDT 2021


aeubanks created this revision.
Herald added subscribers: dexonsmith, jdoerfert, hiraditya.
aeubanks requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

The opaque pointer type is essentially just a normal pointer type with a
null pointee type.

This also adds support for the opaque pointer type to the bitcode
reader/writer, as well as to textual IR.

To avoid confusion with existing pointer types, we disallow creating a
pointer to an opaque pointer.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D101704

Files:
  llvm/docs/LangRef.rst
  llvm/include/llvm/Bitcode/LLVMBitCodes.h
  llvm/include/llvm/IR/DerivedTypes.h
  llvm/lib/AsmParser/LLLexer.cpp
  llvm/lib/AsmParser/LLParser.cpp
  llvm/lib/Bitcode/Reader/BitcodeReader.cpp
  llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
  llvm/lib/IR/AsmWriter.cpp
  llvm/lib/IR/LLVMContextImpl.h
  llvm/lib/IR/Type.cpp
  llvm/test/Assembler/opaque-ptr.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D101704.342189.patch
Type: text/x-patch
Size: 10912 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210502/a682995d/attachment.bin>


More information about the llvm-commits mailing list