[llvm] [LangRef] Try to clarify some Metadata semantics (PR #81948)
Adrian Prantl via llvm-commits
llvm-commits at lists.llvm.org
Thu Feb 15 18:43:01 PST 2024
================
@@ -5574,34 +5574,106 @@ occurs on.
Metadata
========
-LLVM IR allows metadata to be attached to instructions and global objects in the
-program that can convey extra information about the code to the optimizers and
-code generator. One example application of metadata is source-level
-debug information. There are two metadata primitives: strings and nodes.
+LLVM IR allows metadata to be attached to instructions and global objects in
+the program that can convey extra information about the code to the optimizers
+and code generator.
-Metadata does not have a type, and is not a value. If referenced from a
-``call`` instruction, it uses the ``metadata`` type.
+There are two metadata primitives: strings and nodes. There are
+also specialized nodes which have a distinguished name and a set of named
+arguments.
+
+.. note::
+
+ One example application of metadata is source-level debug information,
+ which is currently the only use of specialized nodes.
----------------
adrian-prantl wrote:
```suggestion
which is currently the only user of specialized nodes.
```
https://github.com/llvm/llvm-project/pull/81948
More information about the llvm-commits
mailing list