capstone/arch/ARC/ARCInstPrinter.h
Rot127 d7ef910bc6
Rebased #2570 (#2614)
* Add ARC files

* Added ARC files for successful compilation

* Refactor ARC files

* Add ARC c/cs tests

* Add ARC python test/bindings

* Add ARC to CI/CD

* Avoid omitting parameter names

* Update cs files

* Fix ARC bugs

* Update ARC python bindings

* Refactor and update ARC test files

* Add detail flag to arc test

* Fix ARC test problems

* Fix ARCMapping compile error

* Replace __CHAR_BIT__ to CHAR_BIT

* Add credits and ARC info

* Update ARC to match the latest next

* Python formatting

* Remove asserts on 'Unknown condition code passed'

* Add ARC to some more documentation

* Add ARC to Targets constants

* Add ARC support to llvm-tblgen

* Replace asserts & add Expr handling

* Check DecodeGPR32RegisterClass return value

* Fix fieldFromInstruction patch

* Refactor ARC

* Reformat python files

* Fix incorrect import

* Update inc files and insn names

* Update python files

* Disable AArch64 Linux wheel build due to https://github.com/capstone-engine/capstone/issues/2615.

---------

Co-authored-by: R33v0LT <sibirtsevdl@gmail.com>
2025-01-28 22:34:24 +08:00

58 lines
2.3 KiB
C

/* Capstone Disassembly Engine, http://www.capstone-engine.org */
/* By Nguyen Anh Quynh <aquynh@gmail.com>, 2013-2022, */
/* Rot127 <unisono@quyllur.org> 2022-2023 */
/* Automatically translated source file from LLVM. */
/* LLVM-commit: <commit> */
/* LLVM-tag: <tag> */
/* Only small edits allowed. */
/* For multiple similar edits, please create a Patch for the translator. */
/* Capstone's C++ file translator: */
/* https://github.com/capstone-engine/capstone/tree/next/suite/auto-sync */
//===- ARCInstPrinter.h - Convert ARC MCInst to assembly syntax -*- 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
//
//===----------------------------------------------------------------------===//
///
/// \file
/// This file contains the declaration of the ARCInstPrinter class,
/// which is used to print ARC MCInst to a .s file.
///
//===----------------------------------------------------------------------===//
#ifndef LLVM_LIB_TARGET_ARC_INSTPRINTER_ARCINSTPRINTER_H
#define LLVM_LIB_TARGET_ARC_INSTPRINTER_ARCINSTPRINTER_H
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <capstone/platform.h>
#include "../../SStream.h"
#include "../../MCInst.h"
#define CONCAT(a, b) CONCAT_(a, b)
#define CONCAT_(a, b) a##_##b
// Autogenerated by tblgen.
static void printInstruction(MCInst *MI, uint64_t Address, SStream *O);
static void printRegName(SStream *OS, MCRegister Reg);
static void printInst(MCInst *MI, uint64_t Address, const char *Annot, SStream *O);
static void printCCOperand(MCInst *MI, int OpNum, SStream *O);
static void printU6(MCInst *MI, int OpNum, SStream *O);
static void printMemOperandRI(MCInst *MI, unsigned OpNum, SStream *O);
static void printOperand(MCInst *MI, unsigned OpNum, SStream *O);
static void printOperandAddr(MCInst *MI, uint64_t Address, unsigned OpNum, SStream *O);
static void printPredicateOperand(MCInst *MI, unsigned OpNum, SStream *O);
static void printBRCCPredicateOperand(MCInst *MI, unsigned OpNum, SStream *O);
static void printU6ShiftedBy(unsigned ShiftBy, MCInst *MI, int OpNum, SStream *O);
;
// end namespace llvm
#endif // LLVM_LIB_TARGET_ARC_INSTPRINTER_ARCINSTPRINTER_H