From f6d47a8d9fd93b96b02e89560e1528a07bc1ec4c Mon Sep 17 00:00:00 2001 From: Amara Emerson Date: Mon, 25 Nov 2024 10:51:31 -0800 Subject: [PATCH 1/2] [GlobalISel] Document minimum legality requirements for G_IMPLICIT_DEF. --- llvm/docs/GlobalISel/Legalizer.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/llvm/docs/GlobalISel/Legalizer.rst b/llvm/docs/GlobalISel/Legalizer.rst index 1ff7b304b3a01..cd27a0249c4b3 100644 --- a/llvm/docs/GlobalISel/Legalizer.rst +++ b/llvm/docs/GlobalISel/Legalizer.rst @@ -338,8 +338,8 @@ G_BUILD_VECTOR_TRUNC, G_CONCAT_VECTORS, G_UNMERGE_VALUES, G_PTRTOINT, and G_INTTOPTR have already been noted above. In addition to those, the following operations have requirements: -* At least one G_IMPLICIT_DEF must be legal. This is usually trivial as it - requires no code to be selected. +* For every type that can be produced by any instruction, G_IMPLICIT_DEF must be + legal. This is usually trivial as it requires no code to be selected. * G_PHI must be legal for all types in the producer and consumer typesets. This is usually trivial as it requires no code to be selected. * At least one G_FRAME_INDEX must be legal From abea77e0c106ec2ece10094fd875d323f3ef81ff Mon Sep 17 00:00:00 2001 From: Amara Emerson Date: Mon, 25 Nov 2024 13:52:35 -0800 Subject: [PATCH 2/2] Remove imprecise statement. --- llvm/docs/GlobalISel/Legalizer.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/llvm/docs/GlobalISel/Legalizer.rst b/llvm/docs/GlobalISel/Legalizer.rst index cd27a0249c4b3..0e256ac7781cc 100644 --- a/llvm/docs/GlobalISel/Legalizer.rst +++ b/llvm/docs/GlobalISel/Legalizer.rst @@ -339,7 +339,7 @@ G_INTTOPTR have already been noted above. In addition to those, the following operations have requirements: * For every type that can be produced by any instruction, G_IMPLICIT_DEF must be - legal. This is usually trivial as it requires no code to be selected. + legal. * G_PHI must be legal for all types in the producer and consumer typesets. This is usually trivial as it requires no code to be selected. * At least one G_FRAME_INDEX must be legal