CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
87 lines
3.8 KiB
C++
87 lines
3.8 KiB
C++
//== SystemZInstPrinterCommon.h - Common SystemZ InstPrinter funcs *- C++ -*==//
|
|
//
|
|
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
|
|
// See https://llvm.org/LICENSE.txt for license information.
|
|
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
//
|
|
// This class prints a SystemZ MCInst to a .s file.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
#ifndef LLVM_LIB_TARGET_SYSTEMZ_MCTARGETDESC_SYSTEMZINSTPRINTERCOMMON_H
|
|
#define LLVM_LIB_TARGET_SYSTEMZ_MCTARGETDESC_SYSTEMZINSTPRINTERCOMMON_H
|
|
|
|
#include "SystemZMCAsmInfo.h"
|
|
#include "llvm/MC/MCInstPrinter.h"
|
|
#include "llvm/MC/MCRegister.h"
|
|
#include <cstdint>
|
|
|
|
namespace llvm {
|
|
|
|
class MCOperand;
|
|
|
|
class SystemZInstPrinterCommon : public MCInstPrinter {
|
|
public:
|
|
SystemZInstPrinterCommon(const MCAsmInfo &MAI, const MCInstrInfo &MII,
|
|
const MCRegisterInfo &MRI)
|
|
: MCInstPrinter(MAI, MII, MRI) {}
|
|
|
|
// Print an address with the given base, displacement and index.
|
|
void printAddress(const MCAsmInfo *MAI, MCRegister Base,
|
|
const MCOperand &DispMO, MCRegister Index, raw_ostream &O);
|
|
|
|
// Print the given operand.
|
|
void printOperand(const MCOperand &MO, const MCAsmInfo *MAI, raw_ostream &O);
|
|
|
|
virtual void printFormattedRegName(const MCAsmInfo *MAI, MCRegister Reg,
|
|
raw_ostream &O) {}
|
|
|
|
// Override MCInstPrinter.
|
|
void printRegName(raw_ostream &O, MCRegister Reg) override;
|
|
|
|
protected:
|
|
template <unsigned N>
|
|
void printUImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
template <unsigned N>
|
|
void printSImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
|
|
// Print various types of operand.
|
|
void printOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printOperand(const MCInst *MI, uint64_t /*Address*/, unsigned OpNum,
|
|
raw_ostream &O) {
|
|
printOperand(MI, OpNum, O);
|
|
}
|
|
void printBDAddrOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printBDXAddrOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printBDLAddrOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printBDRAddrOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printBDVAddrOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printLXAAddrOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printU1ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printU2ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printU3ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printU4ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printS8ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printU8ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printU12ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printS16ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printU16ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printS32ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printU32ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printU48ImmOperand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
void printPCRelOperand(const MCInst *MI, uint64_t Address, int OpNum,
|
|
raw_ostream &O);
|
|
void printPCRelTLSOperand(const MCInst *MI, uint64_t Address, int OpNum,
|
|
raw_ostream &O);
|
|
|
|
// Print the mnemonic for a condition-code mask ("ne", "lh", etc.)
|
|
// This forms part of the instruction name rather than the operand list.
|
|
void printCond4Operand(const MCInst *MI, int OpNum, raw_ostream &O);
|
|
};
|
|
|
|
} // end namespace llvm
|
|
|
|
#endif // LLVM_LIB_TARGET_SYSTEMZ_MCTARGETDESC_SYSTEMZINSTPRINTERCOMMON_H
|