LLVM 17.0.0git
AMDGPUInstrInfo.h
Go to the documentation of this file.
1//===-- AMDGPUInstrInfo.h - AMDGPU Instruction Information ------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9/// \file
10/// Contains the definition of a TargetInstrInfo class that is common
11/// to all AMD GPUs.
12//
13//===----------------------------------------------------------------------===//
14
15#ifndef LLVM_LIB_TARGET_AMDGPU_AMDGPUINSTRINFO_H
16#define LLVM_LIB_TARGET_AMDGPU_AMDGPUINSTRINFO_H
17
19
20namespace llvm {
21
22class GCNSubtarget;
23class MachineMemOperand;
24
26public:
27 explicit AMDGPUInstrInfo(const GCNSubtarget &st);
28
29 static bool isUniformMMO(const MachineMemOperand *MMO);
30};
31
32namespace AMDGPU {
33
35 unsigned Intr;
36 uint8_t RsrcArg;
37 bool IsImage;
38};
40
42 unsigned Intr;
43 unsigned D16HelperIntr;
44};
46
48 unsigned Intr;
49 unsigned BaseOpcode;
50 MIMGDim Dim;
51
53 uint8_t NumBiasArgs;
55 uint8_t NumGradients;
56 uint8_t NumDmask;
57 uint8_t NumData;
58 uint8_t NumVAddrs;
59 uint8_t NumArgs;
60
61 uint8_t DMaskIndex;
62 uint8_t VAddrStart;
63 uint8_t OffsetIndex;
64 uint8_t BiasIndex;
67 uint8_t CoordStart;
68 uint8_t LodIndex;
69 uint8_t MipIndex;
70 uint8_t VAddrEnd;
71 uint8_t RsrcIndex;
72 uint8_t SampIndex;
73 uint8_t UnormIndex;
76
77 uint8_t BiasTyArg;
79 uint8_t CoordTyArg;
80};
82
84getImageDimIntrinsicByBaseOpcode(unsigned BaseOpcode, unsigned Dim);
85
86} // end AMDGPU namespace
87} // End llvm namespace
88
89#endif
unsigned Intr
static bool isUniformMMO(const MachineMemOperand *MMO)
A description of a memory reference used in the backend.
const ImageDimIntrinsicInfo * getImageDimIntrinsicByBaseOpcode(unsigned BaseOpcode, unsigned Dim)
const D16ImageDimIntrinsic * lookupD16ImageDimIntrinsic(unsigned Intr)
const ImageDimIntrinsicInfo * getImageDimIntrinsicInfo(unsigned Intr)
const RsrcIntrinsic * lookupRsrcIntrinsic(unsigned Intr)
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18