[llvm] [AMDGPU] Remove int types from isSISrcFPOperand (PR #67401)

Stanislav Mekhanoshin via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 26 01:24:22 PDT 2023


https://github.com/rampitec created https://github.com/llvm/llvm-project/pull/67401

This is NFCI, I don't believe there are any instructions using packed types in the ins dag, only in patterns, and the affected function is only used in the asm parser. However, int types shall not be reported as fp types.

This may be usesul if we create an asm syntax for packed fp literals which we currently don't. If/when we do it that shall affect if we accept FP modifiers on these types or not. Say we could create a syntax like v2(-lit1, |lit2|) that would matter then.

>From 0926a339d4e74142f2c8ee65d60a0d9cea6bef19 Mon Sep 17 00:00:00 2001
From: Stanislav Mekhanoshin <Stanislav.Mekhanoshin at amd.com>
Date: Tue, 26 Sep 2023 01:15:04 -0700
Subject: [PATCH] [AMDGPU] Remove int types from isSISrcFPOperand

This is NFCI, I don't believe there are any instructions using packed
types in the ins dag, only in patterns, and the affected function is
only used in the asm parser. However, int types shall not be reported
as fp types.

This may be usesul if we create an asm syntax for packed fp literals
which we currently don't. If/when we do it that shall affect if we
accept FP modifiers on these types or not. Say we could create a
syntax like v2(-lit1, |lit2|) that would matter then.
---
 llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp b/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
index dc7656af48a41b3..da664c93d188963 100644
--- a/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
+++ b/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
@@ -2237,16 +2237,13 @@ bool isSISrcFPOperand(const MCInstrDesc &Desc, unsigned OpNo) {
   case AMDGPU::OPERAND_REG_IMM_FP16:
   case AMDGPU::OPERAND_REG_IMM_FP16_DEFERRED:
   case AMDGPU::OPERAND_REG_IMM_V2FP16:
-  case AMDGPU::OPERAND_REG_IMM_V2INT16:
   case AMDGPU::OPERAND_REG_INLINE_C_FP32:
   case AMDGPU::OPERAND_REG_INLINE_C_FP64:
   case AMDGPU::OPERAND_REG_INLINE_C_FP16:
   case AMDGPU::OPERAND_REG_INLINE_C_V2FP16:
-  case AMDGPU::OPERAND_REG_INLINE_C_V2INT16:
   case AMDGPU::OPERAND_REG_INLINE_AC_FP32:
   case AMDGPU::OPERAND_REG_INLINE_AC_FP16:
   case AMDGPU::OPERAND_REG_INLINE_AC_V2FP16:
-  case AMDGPU::OPERAND_REG_INLINE_AC_V2INT16:
   case AMDGPU::OPERAND_REG_IMM_V2FP32:
   case AMDGPU::OPERAND_REG_INLINE_C_V2FP32:
   case AMDGPU::OPERAND_REG_INLINE_AC_FP64:



More information about the llvm-commits mailing list