FFmpeg
Loading...
Searching...
No Matches
rasm.h File Reference
#include <stdbool.h>
#include <stddef.h>
#include <stdint.h>
#include <stdio.h>
#include "libavutil/attributes.h"
#include "libavutil/bprint.h"
#include "libavutil/avassert.h"

Go to the source code of this file.

Data Structures

union  RasmOp
 Runtime assembler for AArch64. More...
 
struct  RasmNodeInsn
 
struct  RasmNodeComment
 
struct  RasmNodeLabel
 
struct  RasmNodeFunc
 
struct  RasmNodeDirective
 
struct  RasmNode
 
struct  RasmFunction
 
struct  RasmEntry
 
struct  RasmContext
 
struct  AArch64VecViews
 This helper structure is used to mimic the assembler syntax for vector register modifiers. More...
 

Macros

#define OPN   rasm_op_none()
 
#define IMM(val)
 
#define AARCH64_COND_EQ   0x0
 
#define AARCH64_COND_NE   0x1
 
#define AARCH64_COND_HS   0x2
 
#define AARCH64_COND_CS   AARCH64_COND_HS
 
#define AARCH64_COND_LO   0x3
 
#define AARCH64_COND_CC   AARCH64_COND_LO
 
#define AARCH64_COND_MI   0x4
 
#define AARCH64_COND_PL   0x5
 
#define AARCH64_COND_VS   0x6
 
#define AARCH64_COND_VC   0x7
 
#define AARCH64_COND_HI   0x8
 
#define AARCH64_COND_LS   0x9
 
#define AARCH64_COND_GE   0xa
 
#define AARCH64_COND_LT   0xb
 
#define AARCH64_COND_GT   0xc
 
#define AARCH64_COND_LE   0xd
 
#define AARCH64_COND_AL   0xe
 
#define AARCH64_COND_NV   0xf
 
#define A64OP_VEC_VIEWS4(op)
 
#define AARCH64_BASE_OFFSET   0
 
#define AARCH64_BASE_PRE   1
 
#define AARCH64_BASE_POST   2
 
#define i_none(rctx)
 
#define i_add(rctx, op0, op1, op2)
 
#define i_addv(rctx, op0, op1)
 
#define i_adr(rctx, op0, op1)
 
#define i_and(rctx, op0, op1, op2)
 
#define i_b(rctx, op0)
 
#define i_bcond(rctx, op0, op1)
 
#define i_blr(rctx, op0)
 
#define i_br(rctx, op0)
 
#define i_cmp(rctx, op0, op1)
 
#define i_csel(rctx, op0, op1, op2, op3)
 
#define i_dup(rctx, op0, op1)
 
#define i_fadd(rctx, op0, op1, op2)
 
#define i_fcvtzu(rctx, op0, op1)
 
#define i_fmax(rctx, op0, op1, op2)
 
#define i_fmin(rctx, op0, op1, op2)
 
#define i_fmla(rctx, op0, op1, op2)
 
#define i_fmul(rctx, op0, op1, op2)
 
#define i_ins(rctx, op0, op1)
 
#define i_ld1(rctx, op0, op1)
 
#define i_ld1r(rctx, op0, op1)
 
#define i_ld2(rctx, op0, op1)
 
#define i_ld3(rctx, op0, op1)
 
#define i_ld4(rctx, op0, op1)
 
#define i_ldp(rctx, op0, op1, op2)
 
#define i_ldr(rctx, op0, op1)
 
#define i_ldrb(rctx, op0, op1)
 
#define i_ldrh(rctx, op0, op1)
 
#define i_lsr(rctx, op0, op1, op2)
 
#define i_mov(rctx, op0, op1)
 
#define i_movi(rctx, op0, op1)
 
#define i_mul(rctx, op0, op1, op2)
 
#define i_orr(rctx, op0, op1, op2)
 
#define i_ret(rctx)
 
#define i_rev16(rctx, op0, op1)
 
#define i_rev32(rctx, op0, op1)
 
#define i_shl(rctx, op0, op1, op2)
 
#define i_st1(rctx, op0, op1)
 
#define i_st2(rctx, op0, op1)
 
#define i_st3(rctx, op0, op1)
 
#define i_st4(rctx, op0, op1)
 
#define i_stp(rctx, op0, op1, op2)
 
#define i_str(rctx, op0, op1)
 
#define i_sub(rctx, op0, op1, op2)
 
#define i_subs(rctx, op0, op1, op2)
 
#define i_tbl(rctx, op0, op1, op2)
 
#define i_ubfiz(rctx, op0, op1, op2, op3)
 
#define i_ucvtf(rctx, op0, op1)
 
#define i_umax(rctx, op0, op1, op2)
 
#define i_umin(rctx, op0, op1, op2)
 
#define i_uqxtn(rctx, op0, op1)
 
#define i_ushl(rctx, op0, op1, op2)
 
#define i_ushll(rctx, op0, op1, op2)
 
#define i_ushll2(rctx, op0, op1, op2)
 
#define i_ushr(rctx, op0, op1, op2)
 
#define i_uxtl(rctx, op0, op1)
 
#define i_uxtl2(rctx, op0, op1)
 
#define i_xtn(rctx, op0, op1)
 
#define i_zip1(rctx, op0, op1, op2)
 
#define i_zip2(rctx, op0, op1, op2)
 
#define i_beq(rctx, id)
 
#define i_bne(rctx, id)
 
#define i_bhs(rctx, id)
 
#define i_bcs(rctx, id)
 
#define i_blo(rctx, id)
 
#define i_bcc(rctx, id)
 
#define i_bmi(rctx, id)
 
#define i_bpl(rctx, id)
 
#define i_bvs(rctx, id)
 
#define i_bvc(rctx, id)
 
#define i_bhi(rctx, id)
 
#define i_bls(rctx, id)
 
#define i_bge(rctx, id)
 
#define i_blt(rctx, id)
 
#define i_bgt(rctx, id)
 
#define i_ble(rctx, id)
 
#define i_and16b(rctx, op0, op1, op2)
 
#define i_mov16b(rctx, op0, op1)
 
#define i_orr16b(rctx, op0, op1, op2)
 

Enumerations

enum  RasmOpType { RASM_OP_NONE = 0 , RASM_OP_IMM , RASM_OP_LABEL , RASM_OP_NB }
 
enum  RasmNodeType {
  RASM_NODE_INSN , RASM_NODE_COMMENT , RASM_NODE_LABEL , RASM_NODE_FUNCTION ,
  RASM_NODE_ENDFUNC , RASM_NODE_DIRECTIVE , RASM_NODE_DATA
}
 
enum  RasmEntryType { RASM_ENTRY_FUNC , RASM_ENTRY_DATA }
 
enum  AArch64InsnId {
  AARCH64_INSN_NONE = 0 , AARCH64_INSN_ADD , AARCH64_INSN_ADDV , AARCH64_INSN_ADR ,
  AARCH64_INSN_AND , AARCH64_INSN_B , AARCH64_INSN_BCOND , AARCH64_INSN_BLR ,
  AARCH64_INSN_BR , AARCH64_INSN_CMP , AARCH64_INSN_CSEL , AARCH64_INSN_DUP ,
  AARCH64_INSN_FADD , AARCH64_INSN_FCVTZU , AARCH64_INSN_FMAX , AARCH64_INSN_FMIN ,
  AARCH64_INSN_FMLA , AARCH64_INSN_FMUL , AARCH64_INSN_INS , AARCH64_INSN_LD1 ,
  AARCH64_INSN_LD1R , AARCH64_INSN_LD2 , AARCH64_INSN_LD3 , AARCH64_INSN_LD4 ,
  AARCH64_INSN_LDP , AARCH64_INSN_LDR , AARCH64_INSN_LDRB , AARCH64_INSN_LDRH ,
  AARCH64_INSN_LSR , AARCH64_INSN_MOV , AARCH64_INSN_MOVI , AARCH64_INSN_MUL ,
  AARCH64_INSN_ORR , AARCH64_INSN_RET , AARCH64_INSN_REV16 , AARCH64_INSN_REV32 ,
  AARCH64_INSN_SHL , AARCH64_INSN_ST1 , AARCH64_INSN_ST2 , AARCH64_INSN_ST3 ,
  AARCH64_INSN_ST4 , AARCH64_INSN_STP , AARCH64_INSN_STR , AARCH64_INSN_SUB ,
  AARCH64_INSN_SUBS , AARCH64_INSN_TBL , AARCH64_INSN_UBFIZ , AARCH64_INSN_UCVTF ,
  AARCH64_INSN_UMAX , AARCH64_INSN_UMIN , AARCH64_INSN_UQXTN , AARCH64_INSN_USHL ,
  AARCH64_INSN_USHLL , AARCH64_INSN_USHLL2 , AARCH64_INSN_USHR , AARCH64_INSN_UXTL ,
  AARCH64_INSN_UXTL2 , AARCH64_INSN_XTN , AARCH64_INSN_ZIP1 , AARCH64_INSN_ZIP2 ,
  AARCH64_INSN_NB
}
 
enum  AArch64OpType {
  AARCH64_OP_GPR = RASM_OP_NB , AARCH64_OP_VEC , AARCH64_OP_BASE , AARCH64_OP_COND ,
  AARCH64_OP_NB
}
 

Functions

static RasmOp rasm_op_new (int type)
 
static uint8_t rasm_op_type (RasmOp op)
 
static RasmOp rasm_op_none (void)
 
static RasmOp rasm_op_imm (int32_t val)
 
static int32_t rasm_op_imm_val (RasmOp op)
 
static RasmOp rasm_op_label (int id)
 
static int rasm_op_label_id (RasmOp op)
 
RasmContextrasm_alloc (void)
 
void rasm_free (RasmContext **prctx)
 
RasmNoderasm_add_insn (RasmContext *rctx, int id, RasmOp op0, RasmOp op1, RasmOp op2, RasmOp op3)
 
RasmNoderasm_add_comment (RasmContext *rctx, const char *comment)
 
RasmNoderasm_add_commentf (RasmContext *rctx, char *s, size_t n, const char *fmt,...) av_printf_format(4
 
RasmNode RasmNoderasm_add_label (RasmContext *rctx, int id)
 
RasmNoderasm_add_func (RasmContext *rctx, int id, bool export, bool jumpable)
 
RasmNoderasm_add_endfunc (RasmContext *rctx)
 
RasmNoderasm_add_directive (RasmContext *rctx, const char *text)
 
RasmNoderasm_get_current_node (RasmContext *rctx)
 
RasmNoderasm_set_current_node (RasmContext *rctx, RasmNode *node)
 
int rasm_func_begin (RasmContext *rctx, const char *name, bool export, bool jumpable)
 
int rasm_new_label (RasmContext *rctx, const char *name)
 Allocate a new label ID with the given name.
 
int rasm_new_labelf (RasmContext *rctx, char *s, size_t n, const char *fmt,...) av_printf_format(4
 
int void rasm_annotate (RasmContext *rctx, const char *comment)
 
void rasm_annotatef (RasmContext *rctx, char *s, size_t n, const char *fmt,...) av_printf_format(4
 
void void rasm_annotate_next (RasmContext *rctx, const char *comment)
 
void rasm_annotate_nextf (RasmContext *rctx, char *s, size_t n, const char *fmt,...) av_printf_format(4
 
void int rasm_print (RasmContext *rctx, AVBPrint *bp)
 
static RasmOp a64op_make_gpr (uint8_t n, uint8_t size)
 
static uint8_t a64op_gpr_n (RasmOp op)
 
static uint8_t a64op_gpr_size (RasmOp op)
 
static RasmOp a64op_gpw (uint8_t n)
 
static RasmOp a64op_gpx (uint8_t n)
 
static RasmOp a64op_lr (void)
 
static RasmOp a64op_sp (void)
 
static RasmOp a64op_w (RasmOp op)
 
static RasmOp a64op_x (RasmOp op)
 
static RasmOp a64op_make_vec (uint8_t n, uint8_t el_count, uint8_t el_size)
 
static uint8_t a64op_vec_n (RasmOp op)
 
static uint8_t a64op_vec_el_count (RasmOp op)
 
static uint8_t a64op_vec_el_size (RasmOp op)
 
static uint8_t a64op_vec_num_regs (RasmOp op)
 
static uint8_t a64op_vec_idx_p1 (RasmOp op)
 
static RasmOp a64op_vec (uint8_t n)
 
static RasmOp a64op_vecb (uint8_t n)
 
static RasmOp a64op_vech (uint8_t n)
 
static RasmOp a64op_vecs (uint8_t n)
 
static RasmOp a64op_vecd (uint8_t n)
 
static RasmOp a64op_vecq (uint8_t n)
 
static RasmOp a64op_vec8b (uint8_t n)
 
static RasmOp a64op_vec16b (uint8_t n)
 
static RasmOp a64op_vec4h (uint8_t n)
 
static RasmOp a64op_vec8h (uint8_t n)
 
static RasmOp a64op_vec2s (uint8_t n)
 
static RasmOp a64op_vec4s (uint8_t n)
 
static RasmOp a64op_vec2d (uint8_t n)
 
static RasmOp a64op_veclist (RasmOp op0, RasmOp op1, RasmOp op2, RasmOp op3)
 Create register-list operand for structured load/store instructions.
 
static RasmOp a64op_elem (RasmOp op, uint8_t idx)
 
static RasmOp v_b (RasmOp op)
 
static RasmOp v_h (RasmOp op)
 
static RasmOp v_s (RasmOp op)
 
static RasmOp v_d (RasmOp op)
 
static RasmOp v_q (RasmOp op)
 
static RasmOp v_8b (RasmOp op)
 
static RasmOp v_16b (RasmOp op)
 
static RasmOp v_4h (RasmOp op)
 
static RasmOp v_8h (RasmOp op)
 
static RasmOp v_2s (RasmOp op)
 
static RasmOp v_4s (RasmOp op)
 
static RasmOp v_2d (RasmOp op)
 
static RasmOp vv_1 (RasmOp op0)
 
static RasmOp vv_2 (RasmOp op0, RasmOp op1)
 
static RasmOp vv_3 (RasmOp op0, RasmOp op1, RasmOp op2)
 
static RasmOp vv_4 (RasmOp op0, RasmOp op1, RasmOp op2, RasmOp op3)
 
AArch64VecViews a64op_vec_views (RasmOp op)
 
static RasmOp a64op_make_base (uint8_t n, uint8_t mode, int16_t imm)
 
static int16_t a64op_base_imm (RasmOp op)
 
static uint8_t a64op_base_n (RasmOp op)
 
static uint8_t a64op_base_mode (RasmOp op)
 
static RasmOp a64op_base (RasmOp op)
 
static RasmOp a64op_off (RasmOp op, int16_t imm)
 
static RasmOp a64op_pre (RasmOp op, int16_t imm)
 
static RasmOp a64op_post (RasmOp op, int16_t imm)
 
static RasmOp a64op_cond (int cond)
 
static uint8_t a64op_cond_val (RasmOp op)
 
static RasmOp a64cond_eq (void)
 
static RasmOp a64cond_ne (void)
 
static RasmOp a64cond_hs (void)
 
static RasmOp a64cond_cs (void)
 
static RasmOp a64cond_lo (void)
 
static RasmOp a64cond_cc (void)
 
static RasmOp a64cond_mi (void)
 
static RasmOp a64cond_pl (void)
 
static RasmOp a64cond_vs (void)
 
static RasmOp a64cond_vc (void)
 
static RasmOp a64cond_hi (void)
 
static RasmOp a64cond_ls (void)
 
static RasmOp a64cond_ge (void)
 
static RasmOp a64cond_lt (void)
 
static RasmOp a64cond_gt (void)
 
static RasmOp a64cond_le (void)
 
static RasmOp a64cond_al (void)
 
static RasmOp a64cond_nv (void)
 

Macro Definition Documentation

◆ OPN

#define OPN   rasm_op_none()

Definition at line 76 of file rasm.h.

Referenced by vv_1(), vv_2(), and vv_3().

◆ IMM

◆ AARCH64_COND_EQ

#define AARCH64_COND_EQ   0x0

Definition at line 321 of file rasm.h.

Referenced by a64cond_eq().

◆ AARCH64_COND_NE

#define AARCH64_COND_NE   0x1

Definition at line 322 of file rasm.h.

Referenced by a64cond_ne().

◆ AARCH64_COND_HS

#define AARCH64_COND_HS   0x2

Definition at line 323 of file rasm.h.

Referenced by a64cond_hs().

◆ AARCH64_COND_CS

#define AARCH64_COND_CS   AARCH64_COND_HS

Definition at line 324 of file rasm.h.

Referenced by a64cond_cs().

◆ AARCH64_COND_LO

#define AARCH64_COND_LO   0x3

Definition at line 325 of file rasm.h.

Referenced by a64cond_lo().

◆ AARCH64_COND_CC

#define AARCH64_COND_CC   AARCH64_COND_LO

Definition at line 326 of file rasm.h.

Referenced by a64cond_cc().

◆ AARCH64_COND_MI

#define AARCH64_COND_MI   0x4

Definition at line 327 of file rasm.h.

Referenced by a64cond_mi().

◆ AARCH64_COND_PL

#define AARCH64_COND_PL   0x5

Definition at line 328 of file rasm.h.

Referenced by a64cond_pl().

◆ AARCH64_COND_VS

#define AARCH64_COND_VS   0x6

Definition at line 329 of file rasm.h.

Referenced by a64cond_vs().

◆ AARCH64_COND_VC

#define AARCH64_COND_VC   0x7

Definition at line 330 of file rasm.h.

Referenced by a64cond_vc().

◆ AARCH64_COND_HI

#define AARCH64_COND_HI   0x8

Definition at line 331 of file rasm.h.

Referenced by a64cond_hi().

◆ AARCH64_COND_LS

#define AARCH64_COND_LS   0x9

Definition at line 332 of file rasm.h.

Referenced by a64cond_ls().

◆ AARCH64_COND_GE

#define AARCH64_COND_GE   0xa

Definition at line 333 of file rasm.h.

Referenced by a64cond_ge().

◆ AARCH64_COND_LT

#define AARCH64_COND_LT   0xb

Definition at line 334 of file rasm.h.

Referenced by a64cond_lt().

◆ AARCH64_COND_GT

#define AARCH64_COND_GT   0xc

Definition at line 335 of file rasm.h.

Referenced by a64cond_gt().

◆ AARCH64_COND_LE

#define AARCH64_COND_LE   0xd

Definition at line 336 of file rasm.h.

Referenced by a64cond_le().

◆ AARCH64_COND_AL

#define AARCH64_COND_AL   0xe

Definition at line 337 of file rasm.h.

Referenced by a64cond_al().

◆ AARCH64_COND_NV

#define AARCH64_COND_NV   0xf

Definition at line 338 of file rasm.h.

Referenced by a64cond_nv().

◆ A64OP_VEC_VIEWS4

#define A64OP_VEC_VIEWS4 ( op)
Value:
{ \
a64op_vec_views((op)[0]), \
a64op_vec_views((op)[1]), \
a64op_vec_views((op)[2]), \
a64op_vec_views((op)[3]), \
}
static int op(uint8_t **dst, const uint8_t *dst_end, GetByteContext *gb, int pixel, int count, int *x, int width, int linesize)
Perform decode operation.
Definition anm.c:76

Definition at line 479 of file rasm.h.

Referenced by asmgen_op_convert(), asmgen_op_read_planar(), asmgen_op_swap_bytes(), asmgen_op_write_nibble(), and asmgen_op_write_planar().

◆ AARCH64_BASE_OFFSET

#define AARCH64_BASE_OFFSET   0

Definition at line 489 of file rasm.h.

Referenced by a64op_base(), a64op_off(), and print_op_base().

◆ AARCH64_BASE_PRE

#define AARCH64_BASE_PRE   1

Definition at line 490 of file rasm.h.

Referenced by a64op_pre(), and print_op_base().

◆ AARCH64_BASE_POST

#define AARCH64_BASE_POST   2

Definition at line 491 of file rasm.h.

Referenced by a64op_post(), and print_op_base().

◆ i_none

#define i_none ( rctx)
Value:
RasmNode * rasm_add_insn(RasmContext *rctx, int id, RasmOp op0, RasmOp op1, RasmOp op2, RasmOp op3)
Definition rasm.c:101
#define OPN
Definition rasm.h:76
@ AARCH64_INSN_NONE
Definition rasm.h:245

Definition at line 545 of file rasm.h.

◆ i_add

#define i_add ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_ADD, op0, op1, op2, OPN)
@ AARCH64_INSN_ADD
Definition rasm.h:247

Definition at line 547 of file rasm.h.

Referenced by asmgen_op_dither(), asmgen_process(), asmgen_process_cps(), and asmgen_setup_scale().

◆ i_addv

#define i_addv ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_ADDV
Definition rasm.h:248

Definition at line 548 of file rasm.h.

Referenced by asmgen_op_write_bit().

◆ i_adr

#define i_adr ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_ADR
Definition rasm.h:249

Definition at line 549 of file rasm.h.

◆ i_and

#define i_and ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_AND, op0, op1, op2, OPN)
@ AARCH64_INSN_AND
Definition rasm.h:250

Definition at line 550 of file rasm.h.

Referenced by asmgen_op_read_bit(), and asmgen_op_read_nibble().

◆ i_b

#define i_b ( rctx,
op0 )
Value:
@ AARCH64_INSN_B
Definition rasm.h:251

Definition at line 551 of file rasm.h.

Referenced by asmgen_process().

◆ i_bcond

#define i_bcond ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_BCOND
Definition rasm.h:252

Definition at line 552 of file rasm.h.

◆ i_blr

#define i_blr ( rctx,
op0 )
Value:
@ AARCH64_INSN_BLR
Definition rasm.h:253

Definition at line 553 of file rasm.h.

Referenced by asmgen_process_cps().

◆ i_br

#define i_br ( rctx,
op0 )
Value:
@ AARCH64_INSN_BR
Definition rasm.h:254

Definition at line 554 of file rasm.h.

Referenced by asmgen_op_cps().

◆ i_cmp

#define i_cmp ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_CMP
Definition rasm.h:255

Definition at line 555 of file rasm.h.

Referenced by asmgen_process().

◆ i_csel

#define i_csel ( rctx,
op0,
op1,
op2,
op3 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_CSEL, op0, op1, op2, op3)
@ AARCH64_INSN_CSEL
Definition rasm.h:256

Definition at line 556 of file rasm.h.

◆ i_dup

#define i_dup ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_DUP
Definition rasm.h:257

Definition at line 557 of file rasm.h.

Referenced by asmgen_op_read_bit(), asmgen_setup_max(), asmgen_setup_min(), asmgen_setup_unpack(), emit_clear(), and linear_pass().

◆ i_fadd

#define i_fadd ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_FADD, op0, op1, op2, OPN)
@ AARCH64_INSN_FADD
Definition rasm.h:258

Definition at line 558 of file rasm.h.

Referenced by asmgen_op_dither(), and linear_pass().

◆ i_fcvtzu

#define i_fcvtzu ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_FCVTZU
Definition rasm.h:259

Definition at line 559 of file rasm.h.

Referenced by asmgen_op_convert().

◆ i_fmax

#define i_fmax ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_FMAX, op0, op1, op2, OPN)
@ AARCH64_INSN_FMAX
Definition rasm.h:260

Definition at line 560 of file rasm.h.

Referenced by asmgen_op_max().

◆ i_fmin

#define i_fmin ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_FMIN, op0, op1, op2, OPN)
@ AARCH64_INSN_FMIN
Definition rasm.h:261

Definition at line 561 of file rasm.h.

Referenced by asmgen_op_min().

◆ i_fmla

#define i_fmla ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_FMLA, op0, op1, op2, OPN)
@ AARCH64_INSN_FMLA
Definition rasm.h:262

Definition at line 562 of file rasm.h.

Referenced by linear_pass().

◆ i_fmul

#define i_fmul ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_FMUL, op0, op1, op2, OPN)
@ AARCH64_INSN_FMUL
Definition rasm.h:263

Definition at line 563 of file rasm.h.

Referenced by asmgen_op_scale(), and linear_pass().

◆ i_ins

#define i_ins ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_INS
Definition rasm.h:264

Definition at line 564 of file rasm.h.

Referenced by asmgen_op_convert(), asmgen_op_read_bit(), and asmgen_op_write_bit().

◆ i_ld1

#define i_ld1 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_LD1
Definition rasm.h:265

Definition at line 565 of file rasm.h.

Referenced by asmgen_setup_linear().

◆ i_ld1r

#define i_ld1r ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_LD1R
Definition rasm.h:266

Definition at line 566 of file rasm.h.

Referenced by asmgen_setup_scale().

◆ i_ld2

#define i_ld2 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_LD2
Definition rasm.h:267

Definition at line 567 of file rasm.h.

Referenced by asmgen_op_read_packed_n().

◆ i_ld3

#define i_ld3 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_LD3
Definition rasm.h:268

Definition at line 568 of file rasm.h.

Referenced by asmgen_op_read_packed_n().

◆ i_ld4

#define i_ld4 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_LD4
Definition rasm.h:269

Definition at line 569 of file rasm.h.

Referenced by asmgen_op_read_packed_n().

◆ i_ldp

#define i_ldp ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_LDP, op0, op1, op2, OPN)
@ AARCH64_INSN_LDP
Definition rasm.h:270

Definition at line 570 of file rasm.h.

Referenced by asmgen_epilogue(), asmgen_op_dither(), and asmgen_op_read_planar().

◆ i_ldr

◆ i_ldrb

#define i_ldrb ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_LDRB
Definition rasm.h:272

Definition at line 572 of file rasm.h.

Referenced by asmgen_op_read_bit().

◆ i_ldrh

#define i_ldrh ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_LDRH
Definition rasm.h:273

Definition at line 573 of file rasm.h.

Referenced by asmgen_op_read_bit().

◆ i_lsr

#define i_lsr ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_LSR, op0, op1, op2, OPN)
@ AARCH64_INSN_LSR
Definition rasm.h:274

Definition at line 574 of file rasm.h.

Referenced by asmgen_op_read_bit().

◆ i_mov

#define i_mov ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_MOV
Definition rasm.h:275

Definition at line 575 of file rasm.h.

Referenced by asmgen_process(), asmgen_process_cps(), asmgen_setup_unpack(), and swizzle_emit().

◆ i_movi

#define i_movi ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_MOVI
Definition rasm.h:276

Definition at line 576 of file rasm.h.

Referenced by asmgen_setup_read_bit(), asmgen_setup_read_nibble(), asmgen_setup_unpack(), and emit_clear().

◆ i_mul

#define i_mul ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_MUL, op0, op1, op2, OPN)
@ AARCH64_INSN_MUL
Definition rasm.h:277

Definition at line 577 of file rasm.h.

Referenced by asmgen_op_scale().

◆ i_orr

#define i_orr ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_ORR, op0, op1, op2, OPN)
@ AARCH64_INSN_ORR
Definition rasm.h:278

Definition at line 578 of file rasm.h.

Referenced by asmgen_op_write_nibble().

◆ i_ret

#define i_ret ( rctx)
Value:
@ AARCH64_INSN_RET
Definition rasm.h:279

Definition at line 579 of file rasm.h.

Referenced by asmgen_op_cps(), and asmgen_process().

◆ i_rev16

#define i_rev16 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_REV16
Definition rasm.h:280

Definition at line 580 of file rasm.h.

Referenced by asmgen_op_swap_bytes().

◆ i_rev32

#define i_rev32 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_REV32
Definition rasm.h:281

Definition at line 581 of file rasm.h.

Referenced by asmgen_op_swap_bytes().

◆ i_shl

#define i_shl ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_SHL, op0, op1, op2, OPN)
@ AARCH64_INSN_SHL
Definition rasm.h:282

Definition at line 582 of file rasm.h.

Referenced by asmgen_op_lshift(), asmgen_op_pack(), and asmgen_op_write_nibble().

◆ i_st1

#define i_st1 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_ST1
Definition rasm.h:283

Definition at line 583 of file rasm.h.

◆ i_st2

#define i_st2 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_ST2
Definition rasm.h:284

Definition at line 584 of file rasm.h.

Referenced by asmgen_op_write_packed_n().

◆ i_st3

#define i_st3 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_ST3
Definition rasm.h:285

Definition at line 585 of file rasm.h.

Referenced by asmgen_op_write_packed_n().

◆ i_st4

#define i_st4 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_ST4
Definition rasm.h:286

Definition at line 586 of file rasm.h.

Referenced by asmgen_op_write_packed_n().

◆ i_stp

#define i_stp ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_STP, op0, op1, op2, OPN)
@ AARCH64_INSN_STP
Definition rasm.h:287

Definition at line 587 of file rasm.h.

Referenced by asmgen_op_write_planar(), and asmgen_prologue().

◆ i_str

#define i_str ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_STR
Definition rasm.h:288

Definition at line 588 of file rasm.h.

Referenced by asmgen_op_write_bit(), asmgen_op_write_nibble(), asmgen_op_write_planar(), and asmgen_prologue().

◆ i_sub

#define i_sub ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_SUB, op0, op1, op2, OPN)
@ AARCH64_INSN_SUB
Definition rasm.h:289

Definition at line 589 of file rasm.h.

◆ i_subs

#define i_subs ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_SUBS, op0, op1, op2, OPN)
@ AARCH64_INSN_SUBS
Definition rasm.h:290

Definition at line 590 of file rasm.h.

◆ i_tbl

#define i_tbl ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_TBL, op0, op1, op2, OPN)
@ AARCH64_INSN_TBL
Definition rasm.h:291

Definition at line 591 of file rasm.h.

◆ i_ubfiz

#define i_ubfiz ( rctx,
op0,
op1,
op2,
op3 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_UBFIZ, op0, op1, op2, op3)
@ AARCH64_INSN_UBFIZ
Definition rasm.h:292

Definition at line 592 of file rasm.h.

Referenced by asmgen_op_dither().

◆ i_ucvtf

#define i_ucvtf ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_UCVTF
Definition rasm.h:293

Definition at line 593 of file rasm.h.

Referenced by asmgen_op_convert().

◆ i_umax

#define i_umax ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_UMAX, op0, op1, op2, OPN)
@ AARCH64_INSN_UMAX
Definition rasm.h:294

Definition at line 594 of file rasm.h.

Referenced by asmgen_op_max().

◆ i_umin

#define i_umin ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_UMIN, op0, op1, op2, OPN)
@ AARCH64_INSN_UMIN
Definition rasm.h:295

Definition at line 595 of file rasm.h.

Referenced by asmgen_op_min().

◆ i_uqxtn

#define i_uqxtn ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_UQXTN
Definition rasm.h:296

Definition at line 596 of file rasm.h.

◆ i_ushl

#define i_ushl ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_USHL, op0, op1, op2, OPN)
@ AARCH64_INSN_USHL
Definition rasm.h:297

Definition at line 597 of file rasm.h.

Referenced by asmgen_op_read_bit(), and asmgen_op_write_bit().

◆ i_ushll

#define i_ushll ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_USHLL, op0, op1, op2, OPN)
@ AARCH64_INSN_USHLL
Definition rasm.h:298

Definition at line 598 of file rasm.h.

◆ i_ushll2

#define i_ushll2 ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_USHLL2, op0, op1, op2, OPN)
@ AARCH64_INSN_USHLL2
Definition rasm.h:299

Definition at line 599 of file rasm.h.

◆ i_ushr

#define i_ushr ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_USHR, op0, op1, op2, OPN)
@ AARCH64_INSN_USHR
Definition rasm.h:300

Definition at line 600 of file rasm.h.

Referenced by asmgen_op_read_nibble(), asmgen_op_rshift(), asmgen_op_unpack(), and asmgen_op_write_nibble().

◆ i_uxtl

#define i_uxtl ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_UXTL
Definition rasm.h:301

Definition at line 601 of file rasm.h.

Referenced by asmgen_op_convert().

◆ i_uxtl2

#define i_uxtl2 ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_UXTL2
Definition rasm.h:302

Definition at line 602 of file rasm.h.

Referenced by asmgen_op_convert().

◆ i_xtn

#define i_xtn ( rctx,
op0,
op1 )
Value:
@ AARCH64_INSN_XTN
Definition rasm.h:303

Definition at line 603 of file rasm.h.

Referenced by asmgen_op_convert(), and asmgen_op_write_nibble().

◆ i_zip1

#define i_zip1 ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_ZIP1, op0, op1, op2, OPN)
@ AARCH64_INSN_ZIP1
Definition rasm.h:304

Definition at line 604 of file rasm.h.

Referenced by asmgen_op_expand(), and asmgen_op_read_nibble().

◆ i_zip2

#define i_zip2 ( rctx,
op0,
op1,
op2 )
Value:
rasm_add_insn(rctx, AARCH64_INSN_ZIP2, op0, op1, op2, OPN)
@ AARCH64_INSN_ZIP2
Definition rasm.h:305

Definition at line 605 of file rasm.h.

Referenced by asmgen_op_expand().

◆ i_beq

#define i_beq ( rctx,
id )
Value:
static RasmOp a64cond_eq(void)
Definition rasm.h:523
#define i_bcond(rctx, op0, op1)
Definition rasm.h:552
static RasmOp rasm_op_label(int id)
Definition rasm.h:96

Definition at line 608 of file rasm.h.

◆ i_bne

#define i_bne ( rctx,
id )
Value:
static RasmOp a64cond_ne(void)
Definition rasm.h:524

Definition at line 609 of file rasm.h.

Referenced by asmgen_process().

◆ i_bhs

#define i_bhs ( rctx,
id )
Value:
static RasmOp a64cond_hs(void)
Definition rasm.h:525

Definition at line 610 of file rasm.h.

◆ i_bcs

#define i_bcs ( rctx,
id )
Value:
static RasmOp a64cond_cs(void)
Definition rasm.h:526

Definition at line 611 of file rasm.h.

◆ i_blo

#define i_blo ( rctx,
id )
Value:
static RasmOp a64cond_lo(void)
Definition rasm.h:527

Definition at line 612 of file rasm.h.

◆ i_bcc

#define i_bcc ( rctx,
id )
Value:
static RasmOp a64cond_cc(void)
Definition rasm.h:528

Definition at line 613 of file rasm.h.

◆ i_bmi

#define i_bmi ( rctx,
id )
Value:
static RasmOp a64cond_mi(void)
Definition rasm.h:529

Definition at line 614 of file rasm.h.

◆ i_bpl

#define i_bpl ( rctx,
id )
Value:
static RasmOp a64cond_pl(void)
Definition rasm.h:530

Definition at line 615 of file rasm.h.

◆ i_bvs

#define i_bvs ( rctx,
id )
Value:
static RasmOp a64cond_vs(void)
Definition rasm.h:531

Definition at line 616 of file rasm.h.

◆ i_bvc

#define i_bvc ( rctx,
id )
Value:
static RasmOp a64cond_vc(void)
Definition rasm.h:532

Definition at line 617 of file rasm.h.

◆ i_bhi

#define i_bhi ( rctx,
id )
Value:
static RasmOp a64cond_hi(void)
Definition rasm.h:533

Definition at line 618 of file rasm.h.

◆ i_bls

#define i_bls ( rctx,
id )
Value:
static RasmOp a64cond_ls(void)
Definition rasm.h:534

Definition at line 619 of file rasm.h.

◆ i_bge

#define i_bge ( rctx,
id )
Value:
static RasmOp a64cond_ge(void)
Definition rasm.h:535

Definition at line 620 of file rasm.h.

◆ i_blt

#define i_blt ( rctx,
id )
Value:
static RasmOp a64cond_lt(void)
Definition rasm.h:536

Definition at line 621 of file rasm.h.

◆ i_bgt

#define i_bgt ( rctx,
id )
Value:
static RasmOp a64cond_gt(void)
Definition rasm.h:537

Definition at line 622 of file rasm.h.

◆ i_ble

#define i_ble ( rctx,
id )
Value:
static RasmOp a64cond_le(void)
Definition rasm.h:538

Definition at line 623 of file rasm.h.

◆ i_and16b

#define i_and16b ( rctx,
op0,
op1,
op2 )
Value:
i_and(rctx, v_16b(op0), v_16b(op1), v_16b(op2))
#define i_and(rctx, op0, op1, op2)
Definition rasm.h:550
static RasmOp v_16b(RasmOp op)
Definition rasm.h:438

Definition at line 626 of file rasm.h.

Referenced by asmgen_op_unpack().

◆ i_mov16b

#define i_mov16b ( rctx,
op0,
op1 )
Value:
i_mov(rctx, v_16b(op0), v_16b(op1) )
#define i_mov(rctx, op0, op1)
Definition rasm.h:575

Definition at line 627 of file rasm.h.

Referenced by asmgen_op_unpack(), asmgen_setup_linear(), and linear_pass().

◆ i_orr16b

#define i_orr16b ( rctx,
op0,
op1,
op2 )
Value:
i_orr(rctx, v_16b(op0), v_16b(op1), v_16b(op2))
#define i_orr(rctx, op0, op1, op2)
Definition rasm.h:578

Definition at line 628 of file rasm.h.

Referenced by asmgen_op_pack().

Enumeration Type Documentation

◆ RasmOpType

enum RasmOpType
Enumerator
RASM_OP_NONE 
RASM_OP_IMM 
RASM_OP_LABEL 
RASM_OP_NB 

Definition at line 62 of file rasm.h.

◆ RasmNodeType

Enumerator
RASM_NODE_INSN 
RASM_NODE_COMMENT 
RASM_NODE_LABEL 
RASM_NODE_FUNCTION 
RASM_NODE_ENDFUNC 
RASM_NODE_DIRECTIVE 
RASM_NODE_DATA 

Definition at line 111 of file rasm.h.

◆ RasmEntryType

Enumerator
RASM_ENTRY_FUNC 
RASM_ENTRY_DATA 

Definition at line 162 of file rasm.h.

◆ AArch64InsnId

Enumerator
AARCH64_INSN_NONE 
AARCH64_INSN_ADD 
AARCH64_INSN_ADDV 
AARCH64_INSN_ADR 
AARCH64_INSN_AND 
AARCH64_INSN_B 
AARCH64_INSN_BCOND 
AARCH64_INSN_BLR 
AARCH64_INSN_BR 
AARCH64_INSN_CMP 
AARCH64_INSN_CSEL 
AARCH64_INSN_DUP 
AARCH64_INSN_FADD 
AARCH64_INSN_FCVTZU 
AARCH64_INSN_FMAX 
AARCH64_INSN_FMIN 
AARCH64_INSN_FMLA 
AARCH64_INSN_FMUL 
AARCH64_INSN_INS 
AARCH64_INSN_LD1 
AARCH64_INSN_LD1R 
AARCH64_INSN_LD2 
AARCH64_INSN_LD3 
AARCH64_INSN_LD4 
AARCH64_INSN_LDP 
AARCH64_INSN_LDR 
AARCH64_INSN_LDRB 
AARCH64_INSN_LDRH 
AARCH64_INSN_LSR 
AARCH64_INSN_MOV 
AARCH64_INSN_MOVI 
AARCH64_INSN_MUL 
AARCH64_INSN_ORR 
AARCH64_INSN_RET 
AARCH64_INSN_REV16 
AARCH64_INSN_REV32 
AARCH64_INSN_SHL 
AARCH64_INSN_ST1 
AARCH64_INSN_ST2 
AARCH64_INSN_ST3 
AARCH64_INSN_ST4 
AARCH64_INSN_STP 
AARCH64_INSN_STR 
AARCH64_INSN_SUB 
AARCH64_INSN_SUBS 
AARCH64_INSN_TBL 
AARCH64_INSN_UBFIZ 
AARCH64_INSN_UCVTF 
AARCH64_INSN_UMAX 
AARCH64_INSN_UMIN 
AARCH64_INSN_UQXTN 
AARCH64_INSN_USHL 
AARCH64_INSN_USHLL 
AARCH64_INSN_USHLL2 
AARCH64_INSN_USHR 
AARCH64_INSN_UXTL 
AARCH64_INSN_UXTL2 
AARCH64_INSN_XTN 
AARCH64_INSN_ZIP1 
AARCH64_INSN_ZIP2 
AARCH64_INSN_NB 

Definition at line 244 of file rasm.h.

◆ AArch64OpType

Enumerator
AARCH64_OP_GPR 
AARCH64_OP_VEC 
AARCH64_OP_BASE 
AARCH64_OP_COND 
AARCH64_OP_NB 

Definition at line 311 of file rasm.h.

Function Documentation

◆ rasm_op_new()

static RasmOp rasm_op_new ( int type)
inlinestatic

◆ rasm_op_type()

static uint8_t rasm_op_type ( RasmOp op)
inlinestatic

Definition at line 58 of file rasm.h.

Referenced by a64op_veclist(), print_node_insn(), and print_op().

◆ rasm_op_none()

static RasmOp rasm_op_none ( void )
inlinestatic

Definition at line 71 of file rasm.h.

◆ rasm_op_imm()

static RasmOp rasm_op_imm ( int32_t val)
inlinestatic

Definition at line 80 of file rasm.h.

◆ rasm_op_imm_val()

static int32_t rasm_op_imm_val ( RasmOp op)
inlinestatic

Definition at line 87 of file rasm.h.

Referenced by print_op_imm().

◆ rasm_op_label()

static RasmOp rasm_op_label ( int id)
inlinestatic

Definition at line 96 of file rasm.h.

Referenced by asmgen_process().

◆ rasm_op_label_id()

static int rasm_op_label_id ( RasmOp op)
inlinestatic

Definition at line 103 of file rasm.h.

Referenced by print_op_label().

◆ rasm_alloc()

RasmContext * rasm_alloc ( void )

Definition at line 32 of file rasm.c.

Referenced by asmgen().

◆ rasm_free()

void rasm_free ( RasmContext ** prctx)

Definition at line 37 of file rasm.c.

Referenced by asmgen().

◆ rasm_add_insn()

RasmNode * rasm_add_insn ( RasmContext * rctx,
int id,
RasmOp op0,
RasmOp op1,
RasmOp op2,
RasmOp op3 )

Definition at line 101 of file rasm.c.

◆ rasm_add_comment()

RasmNode * rasm_add_comment ( RasmContext * rctx,
const char * comment )

◆ rasm_add_commentf()

RasmNode * rasm_add_commentf ( RasmContext * rctx,
char * s,
size_t n,
const char * fmt,
... )

◆ rasm_add_label()

RasmNode RasmNode * rasm_add_label ( RasmContext * rctx,
int id )

Definition at line 146 of file rasm.c.

Referenced by asmgen_process(), and rasm_add_commentf().

◆ rasm_add_func()

RasmNode * rasm_add_func ( RasmContext * rctx,
int id,
bool export,
bool jumpable )

Definition at line 155 of file rasm.c.

Referenced by rasm_add_commentf(), and rasm_func_begin().

◆ rasm_add_endfunc()

RasmNode * rasm_add_endfunc ( RasmContext * rctx)

Definition at line 168 of file rasm.c.

Referenced by rasm_add_commentf(), and rasm_func_begin().

◆ rasm_add_directive()

RasmNode * rasm_add_directive ( RasmContext * rctx,
const char * text )

Definition at line 174 of file rasm.c.

Referenced by rasm_add_commentf().

◆ rasm_get_current_node()

RasmNode * rasm_get_current_node ( RasmContext * rctx)

Definition at line 194 of file rasm.c.

Referenced by asmgen_process(), asmgen_set_load_cont_node(), linear_pass(), and rasm_add_commentf().

◆ rasm_set_current_node()

RasmNode * rasm_set_current_node ( RasmContext * rctx,
RasmNode * node )

◆ rasm_func_begin()

int rasm_func_begin ( RasmContext * rctx,
const char * name,
bool export,
bool jumpable )

Definition at line 209 of file rasm.c.

Referenced by asmgen_op_cps(), asmgen_process_cps(), and rasm_add_commentf().

◆ rasm_new_label()

int rasm_new_label ( RasmContext * rctx,
const char * name )

Allocate a new label ID with the given name.

Parameters
namelabel name or NULL for local label
Returns
new label ID, negative error code on failure

Definition at line 282 of file rasm.c.

Referenced by asmgen_process(), rasm_add_commentf(), rasm_func_begin(), and rasm_new_labelf().

◆ rasm_new_labelf()

int rasm_new_labelf ( RasmContext * rctx,
char * s,
size_t n,
const char * fmt,
... )

◆ rasm_annotate()

int void rasm_annotate ( RasmContext * rctx,
const char * comment )

Definition at line 243 of file rasm.c.

Referenced by rasm_annotatef(), and rasm_new_labelf().

◆ rasm_annotatef()

void rasm_annotatef ( RasmContext * rctx,
char * s,
size_t n,
const char * fmt,
... )

◆ rasm_annotate_next()

void void rasm_annotate_next ( RasmContext * rctx,
const char * comment )

◆ rasm_annotate_nextf()

void rasm_annotate_nextf ( RasmContext * rctx,
char * s,
size_t n,
const char * fmt,
... )

◆ rasm_print()

void int rasm_print ( RasmContext * rctx,
AVBPrint * bp )

Definition at line 422 of file rasm_print.c.

Referenced by asmgen(), and rasm_annotate_nextf().

◆ a64op_make_gpr()

static RasmOp a64op_make_gpr ( uint8_t n,
uint8_t size )
inlinestatic

Definition at line 343 of file rasm.h.

Referenced by a64op_gpw(), a64op_gpx(), a64op_lr(), and a64op_sp().

◆ a64op_gpr_n()

static uint8_t a64op_gpr_n ( RasmOp op)
inlinestatic

◆ a64op_gpr_size()

static uint8_t a64op_gpr_size ( RasmOp op)
inlinestatic

Definition at line 352 of file rasm.h.

Referenced by print_op_gpr().

◆ a64op_gpw()

static RasmOp a64op_gpw ( uint8_t n)
inlinestatic

Definition at line 354 of file rasm.h.

Referenced by a64op_w(), asmgen_common_frame(), and asmgen_process_frame().

◆ a64op_gpx()

static RasmOp a64op_gpx ( uint8_t n)
inlinestatic

Definition at line 355 of file rasm.h.

Referenced by a64op_x(), asmgen_common_frame(), asmgen_op_frame(), and asmgen_process_frame().

◆ a64op_lr()

static RasmOp a64op_lr ( void )
inlinestatic

Definition at line 356 of file rasm.h.

Referenced by clobbered_gprs().

◆ a64op_sp()

static RasmOp a64op_sp ( void )
inlinestatic

Definition at line 357 of file rasm.h.

Referenced by asmgen_epilogue(), and asmgen_prologue().

◆ a64op_w()

static RasmOp a64op_w ( RasmOp op)
inlinestatic

Definition at line 360 of file rasm.h.

Referenced by asmgen_op_dither(), asmgen_op_read_bit(), and asmgen_setup_unpack().

◆ a64op_x()

static RasmOp a64op_x ( RasmOp op)
inlinestatic

Definition at line 361 of file rasm.h.

Referenced by asmgen_op_dither().

◆ a64op_make_vec()

static RasmOp a64op_make_vec ( uint8_t n,
uint8_t el_count,
uint8_t el_size )
inlinestatic

◆ a64op_vec_n()

static uint8_t a64op_vec_n ( RasmOp op)
inlinestatic

◆ a64op_vec_el_count()

static uint8_t a64op_vec_el_count ( RasmOp op)
inlinestatic

Definition at line 378 of file rasm.h.

Referenced by print_op_vec().

◆ a64op_vec_el_size()

static uint8_t a64op_vec_el_size ( RasmOp op)
inlinestatic

Definition at line 379 of file rasm.h.

Referenced by print_op_vec().

◆ a64op_vec_num_regs()

static uint8_t a64op_vec_num_regs ( RasmOp op)
inlinestatic

Definition at line 380 of file rasm.h.

Referenced by print_op_vec().

◆ a64op_vec_idx_p1()

static uint8_t a64op_vec_idx_p1 ( RasmOp op)
inlinestatic

Definition at line 381 of file rasm.h.

Referenced by print_op_vec().

◆ a64op_vec()

static RasmOp a64op_vec ( uint8_t n)
inlinestatic

Definition at line 383 of file rasm.h.

Referenced by init_vectors_cps().

◆ a64op_vecb()

static RasmOp a64op_vecb ( uint8_t n)
inlinestatic

Definition at line 384 of file rasm.h.

Referenced by a64op_vec_views(), and v_b().

◆ a64op_vech()

static RasmOp a64op_vech ( uint8_t n)
inlinestatic

Definition at line 385 of file rasm.h.

Referenced by a64op_vec_views(), and v_h().

◆ a64op_vecs()

static RasmOp a64op_vecs ( uint8_t n)
inlinestatic

Definition at line 386 of file rasm.h.

Referenced by a64op_vec_views(), and v_s().

◆ a64op_vecd()

static RasmOp a64op_vecd ( uint8_t n)
inlinestatic

Definition at line 387 of file rasm.h.

Referenced by a64op_vec_views(), and v_d().

◆ a64op_vecq()

static RasmOp a64op_vecq ( uint8_t n)
inlinestatic

Definition at line 388 of file rasm.h.

Referenced by a64op_vec_views(), and v_q().

◆ a64op_vec8b()

static RasmOp a64op_vec8b ( uint8_t n)
inlinestatic

Definition at line 389 of file rasm.h.

Referenced by a64op_vec_views(), and v_8b().

◆ a64op_vec16b()

static RasmOp a64op_vec16b ( uint8_t n)
inlinestatic

Definition at line 390 of file rasm.h.

Referenced by a64op_vec_views(), and v_16b().

◆ a64op_vec4h()

static RasmOp a64op_vec4h ( uint8_t n)
inlinestatic

Definition at line 391 of file rasm.h.

Referenced by a64op_vec_views(), and v_4h().

◆ a64op_vec8h()

static RasmOp a64op_vec8h ( uint8_t n)
inlinestatic

Definition at line 392 of file rasm.h.

Referenced by a64op_vec_views(), and v_8h().

◆ a64op_vec2s()

static RasmOp a64op_vec2s ( uint8_t n)
inlinestatic

Definition at line 393 of file rasm.h.

Referenced by a64op_vec_views(), and v_2s().

◆ a64op_vec4s()

static RasmOp a64op_vec4s ( uint8_t n)
inlinestatic

Definition at line 394 of file rasm.h.

Referenced by a64op_vec_views(), and v_4s().

◆ a64op_vec2d()

static RasmOp a64op_vec2d ( uint8_t n)
inlinestatic

Definition at line 395 of file rasm.h.

Referenced by a64op_vec_views(), and v_2d().

◆ a64op_veclist()

static RasmOp a64op_veclist ( RasmOp op0,
RasmOp op1,
RasmOp op2,
RasmOp op3 )
inlinestatic

Create register-list operand for structured load/store instructions.

Registers must be consecutive.

Definition at line 401 of file rasm.h.

Referenced by vv_1(), vv_2(), vv_3(), and vv_4().

◆ a64op_elem()

static RasmOp a64op_elem ( RasmOp op,
uint8_t idx )
inlinestatic

◆ v_b()

static RasmOp v_b ( RasmOp op)
inlinestatic

Definition at line 430 of file rasm.h.

Referenced by optimize_colors().

◆ v_h()

◆ v_s()

static RasmOp v_s ( RasmOp op)
inlinestatic

Definition at line 432 of file rasm.h.

◆ v_d()

static RasmOp v_d ( RasmOp op)
inlinestatic

Definition at line 433 of file rasm.h.

◆ v_q()

static RasmOp v_q ( RasmOp op)
inlinestatic

Definition at line 434 of file rasm.h.

Referenced by asmgen_op_dither(), asmgen_setup_clear(), asmgen_setup_max(), and asmgen_setup_min().

◆ v_8b()

static RasmOp v_8b ( RasmOp op)
inlinestatic

Definition at line 437 of file rasm.h.

Referenced by emit_clear().

◆ v_16b()

static RasmOp v_16b ( RasmOp op)
inlinestatic

Definition at line 438 of file rasm.h.

Referenced by asmgen_op_pack(), asmgen_setup_unpack(), and emit_clear().

◆ v_4h()

static RasmOp v_4h ( RasmOp op)
inlinestatic

Definition at line 439 of file rasm.h.

◆ v_8h()

static RasmOp v_8h ( RasmOp op)
inlinestatic

Definition at line 440 of file rasm.h.

◆ v_2s()

static RasmOp v_2s ( RasmOp op)
inlinestatic

Definition at line 441 of file rasm.h.

◆ v_4s()

static RasmOp v_4s ( RasmOp op)
inlinestatic

Definition at line 442 of file rasm.h.

◆ v_2d()

static RasmOp v_2d ( RasmOp op)
inlinestatic

Definition at line 443 of file rasm.h.

◆ vv_1()

static RasmOp vv_1 ( RasmOp op0)
inlinestatic

Definition at line 446 of file rasm.h.

Referenced by asmgen_setup_linear(), and asmgen_setup_scale().

◆ vv_2()

static RasmOp vv_2 ( RasmOp op0,
RasmOp op1 )
inlinestatic

Definition at line 447 of file rasm.h.

Referenced by asmgen_op_read_packed_n(), asmgen_op_write_packed_n(), and asmgen_setup_linear().

◆ vv_3()

static RasmOp vv_3 ( RasmOp op0,
RasmOp op1,
RasmOp op2 )
inlinestatic

Definition at line 448 of file rasm.h.

Referenced by asmgen_op_read_packed_n(), asmgen_op_write_packed_n(), and asmgen_setup_linear().

◆ vv_4()

static RasmOp vv_4 ( RasmOp op0,
RasmOp op1,
RasmOp op2,
RasmOp op3 )
inlinestatic

Definition at line 449 of file rasm.h.

Referenced by asmgen_op_read_packed_n(), asmgen_op_write_packed_n(), and asmgen_setup_linear().

◆ a64op_vec_views()

◆ a64op_make_base()

static RasmOp a64op_make_base ( uint8_t n,
uint8_t mode,
int16_t imm )
inlinestatic

Definition at line 493 of file rasm.h.

Referenced by a64op_base(), a64op_off(), a64op_post(), and a64op_pre().

◆ a64op_base_imm()

static int16_t a64op_base_imm ( RasmOp op)
inlinestatic

Definition at line 502 of file rasm.h.

Referenced by print_op_base().

◆ a64op_base_n()

static uint8_t a64op_base_n ( RasmOp op)
inlinestatic

Definition at line 503 of file rasm.h.

Referenced by print_op_base().

◆ a64op_base_mode()

static uint8_t a64op_base_mode ( RasmOp op)
inlinestatic

Definition at line 504 of file rasm.h.

Referenced by print_op_base().

◆ a64op_base()

static RasmOp a64op_base ( RasmOp op)
inlinestatic

Definition at line 506 of file rasm.h.

Referenced by asmgen_op_dither(), asmgen_setup_linear(), and asmgen_setup_scale().

◆ a64op_off()

static RasmOp a64op_off ( RasmOp op,
int16_t imm )
inlinestatic

Definition at line 507 of file rasm.h.

Referenced by asmgen_epilogue(), asmgen_process(), asmgen_process_cps(), and asmgen_prologue().

◆ a64op_pre()

static RasmOp a64op_pre ( RasmOp op,
int16_t imm )
inlinestatic

Definition at line 508 of file rasm.h.

Referenced by asmgen_prologue().

◆ a64op_post()

◆ a64op_cond()

◆ a64op_cond_val()

static uint8_t a64op_cond_val ( RasmOp op)
inlinestatic

Definition at line 521 of file rasm.h.

Referenced by print_node_insn(), and print_op_cond().

◆ a64cond_eq()

static RasmOp a64cond_eq ( void )
inlinestatic

Definition at line 523 of file rasm.h.

◆ a64cond_ne()

static RasmOp a64cond_ne ( void )
inlinestatic

Definition at line 524 of file rasm.h.

◆ a64cond_hs()

static RasmOp a64cond_hs ( void )
inlinestatic

Definition at line 525 of file rasm.h.

◆ a64cond_cs()

static RasmOp a64cond_cs ( void )
inlinestatic

Definition at line 526 of file rasm.h.

◆ a64cond_lo()

static RasmOp a64cond_lo ( void )
inlinestatic

Definition at line 527 of file rasm.h.

◆ a64cond_cc()

static RasmOp a64cond_cc ( void )
inlinestatic

Definition at line 528 of file rasm.h.

◆ a64cond_mi()

static RasmOp a64cond_mi ( void )
inlinestatic

Definition at line 529 of file rasm.h.

◆ a64cond_pl()

static RasmOp a64cond_pl ( void )
inlinestatic

Definition at line 530 of file rasm.h.

◆ a64cond_vs()

static RasmOp a64cond_vs ( void )
inlinestatic

Definition at line 531 of file rasm.h.

◆ a64cond_vc()

static RasmOp a64cond_vc ( void )
inlinestatic

Definition at line 532 of file rasm.h.

◆ a64cond_hi()

static RasmOp a64cond_hi ( void )
inlinestatic

Definition at line 533 of file rasm.h.

◆ a64cond_ls()

static RasmOp a64cond_ls ( void )
inlinestatic

Definition at line 534 of file rasm.h.

◆ a64cond_ge()

static RasmOp a64cond_ge ( void )
inlinestatic

Definition at line 535 of file rasm.h.

◆ a64cond_lt()

static RasmOp a64cond_lt ( void )
inlinestatic

Definition at line 536 of file rasm.h.

◆ a64cond_gt()

static RasmOp a64cond_gt ( void )
inlinestatic

Definition at line 537 of file rasm.h.

◆ a64cond_le()

static RasmOp a64cond_le ( void )
inlinestatic

Definition at line 538 of file rasm.h.

◆ a64cond_al()

static RasmOp a64cond_al ( void )
inlinestatic

Definition at line 539 of file rasm.h.

◆ a64cond_nv()

static RasmOp a64cond_nv ( void )
inlinestatic

Definition at line 540 of file rasm.h.