mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-03 00:33:09 +00:00
01115b1f50
The important fix is that the constant interpolation value is stored in the parameter slot P0, which is encoded as 2. In addition, drop the SI_INTERP_CONST pseudo instruction, pass the parameter slot as an operand to V_INTERP_MOV_F32 instead of hardcoding it there, and add a special operand class for the parameter slots for type checking and pretty printing. NOTE: This is a candidate for the Mesa stable branch. Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Tom Stellard <thomas.stellard@amd.com> git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175193 91177308-0d34-0410-b5e6-96231b3b80d8
55 lines
2.1 KiB
C++
55 lines
2.1 KiB
C++
//===-- AMDGPUInstPrinter.h - AMDGPU MC Inst -> ASM interface ---*- C++ -*-===//
|
|
//
|
|
// The LLVM Compiler Infrastructure
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
//
|
|
/// \file
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
#ifndef AMDGPUINSTPRINTER_H
|
|
#define AMDGPUINSTPRINTER_H
|
|
|
|
#include "llvm/ADT/StringRef.h"
|
|
#include "llvm/MC/MCInstPrinter.h"
|
|
#include "llvm/Support/raw_ostream.h"
|
|
|
|
namespace llvm {
|
|
|
|
class AMDGPUInstPrinter : public MCInstPrinter {
|
|
public:
|
|
AMDGPUInstPrinter(const MCAsmInfo &MAI, const MCInstrInfo &MII,
|
|
const MCRegisterInfo &MRI)
|
|
: MCInstPrinter(MAI, MII, MRI) {}
|
|
|
|
//Autogenerated by tblgen
|
|
void printInstruction(const MCInst *MI, raw_ostream &O);
|
|
static const char *getRegisterName(unsigned RegNo);
|
|
|
|
virtual void printInst(const MCInst *MI, raw_ostream &O, StringRef Annot);
|
|
|
|
private:
|
|
void printOperand(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printInterpSlot(const MCInst *MI, unsigned OpNum, raw_ostream &O);
|
|
void printMemOperand(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printIfSet(const MCInst *MI, unsigned OpNo, raw_ostream &O, StringRef Asm);
|
|
void printAbs(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printClamp(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printLiteral(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printLast(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printNeg(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printOMOD(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printRel(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printUpdateExecMask(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printUpdatePred(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printWrite(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
void printSel(const MCInst *MI, unsigned OpNo, raw_ostream &O);
|
|
};
|
|
|
|
} // End namespace llvm
|
|
|
|
#endif // AMDGPUINSTRPRINTER_H
|