[llvm] [NFC] add explanation to register flags doc (PR #91803)
Florian Mayer via llvm-commits
llvm-commits at lists.llvm.org
Tue May 14 11:15:10 PDT 2024
https://github.com/fmayer updated https://github.com/llvm/llvm-project/pull/91803
>From d000fdc6cc18421465b012326dbac2efba0e7c3d Mon Sep 17 00:00:00 2001
From: Florian Mayer <fmayer at google.com>
Date: Fri, 10 May 2024 13:27:04 -0700
Subject: [PATCH 1/3] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UTF-8?q?itial=20version?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Created using spr 1.3.4
---
llvm/docs/MIRLangRef.rst | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/llvm/docs/MIRLangRef.rst b/llvm/docs/MIRLangRef.rst
index 52ff24daa7fba..c617e4661a5fb 100644
--- a/llvm/docs/MIRLangRef.rst
+++ b/llvm/docs/MIRLangRef.rst
@@ -545,36 +545,47 @@ corresponding internal ``llvm::RegState`` representation:
* - Flag
- Internal Value
+ - Meaning
* - ``implicit``
- ``RegState::Implicit``
+ - Not emitted register (e.g. carry, or temporary result).
* - ``implicit-def``
- ``RegState::ImplicitDefine``
+ - `implicit` and `def`
* - ``def``
- ``RegState::Define``
+ - Register definition.
* - ``dead``
- ``RegState::Dead``
+ - Unused definition.
* - ``killed``
- ``RegState::Kill``
+ - The last use of a register.
* - ``undef``
- ``RegState::Undef``
+ - Value of the register doesn't matter.
* - ``internal``
- ``RegState::InternalRead``
+ - Register reads a value that is defined inside the same instruction or bundle.
* - ``early-clobber``
- ``RegState::EarlyClobber``
+ - Register definition happens before uses.
* - ``debug-use``
- ``RegState::Debug``
+ - Register 'use' is for debugging purpose.
* - ``renamable``
- ``RegState::Renamable``
+ - Register that may be renamed.
.. _subregister-indices:
>From ab45f63672c4e70ca01d129a1dc3e3347996903a Mon Sep 17 00:00:00 2001
From: Florian Mayer <fmayer at google.com>
Date: Fri, 10 May 2024 13:29:35 -0700
Subject: [PATCH 2/3] vhsnh
Created using spr 1.3.4
---
llvm/docs/MIRLangRef.rst | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/llvm/docs/MIRLangRef.rst b/llvm/docs/MIRLangRef.rst
index c617e4661a5fb..41df88b629633 100644
--- a/llvm/docs/MIRLangRef.rst
+++ b/llvm/docs/MIRLangRef.rst
@@ -553,7 +553,7 @@ corresponding internal ``llvm::RegState`` representation:
* - ``implicit-def``
- ``RegState::ImplicitDefine``
- - `implicit` and `def`
+ - ``implicit`` and ``def``
* - ``def``
- ``RegState::Define``
>From 6dab9ff72a1410989553285490f2a077c707c855 Mon Sep 17 00:00:00 2001
From: Florian Mayer <fmayer at google.com>
Date: Tue, 14 May 2024 11:15:03 -0700
Subject: [PATCH 3/3] add comment to keep in sync
---
llvm/docs/MIRLangRef.rst | 3 +++
1 file changed, 3 insertions(+)
diff --git a/llvm/docs/MIRLangRef.rst b/llvm/docs/MIRLangRef.rst
index 41df88b629633..7309e7b68b86a 100644
--- a/llvm/docs/MIRLangRef.rst
+++ b/llvm/docs/MIRLangRef.rst
@@ -540,6 +540,9 @@ Register Flags
The table below shows all of the possible register flags along with the
corresponding internal ``llvm::RegState`` representation:
+..
+ Keep this in sync with MachineInstrBuilder.h
+
.. list-table::
:header-rows: 1
More information about the llvm-commits
mailing list