Home
last modified time | relevance | path

Searched refs:insn (Results 1 – 24 of 24) sorted by relevance

/xen/xen/arch/arm/arm64/
A Dinsn.c34 return (aarch64_insn_is_b(insn) || aarch64_insn_is_bl(insn) || in aarch64_insn_is_branch_imm()
35 aarch64_insn_is_tbz(insn) || aarch64_insn_is_tbnz(insn) || in aarch64_insn_is_branch_imm()
36 aarch64_insn_is_cbz(insn) || aarch64_insn_is_cbnz(insn) || in aarch64_insn_is_branch_imm()
156 return insn; in aarch64_insn_encode_immediate()
182 u32 insn; in aarch64_insn_gen_branch_imm() local
229 if (aarch64_insn_is_b(insn) || aarch64_insn_is_bl(insn)) { in aarch64_get_branch_offset()
234 if (aarch64_insn_is_cbz(insn) || aarch64_insn_is_cbnz(insn) || in aarch64_get_branch_offset()
240 if (aarch64_insn_is_tbz(insn) || aarch64_insn_is_tbnz(insn)) { in aarch64_get_branch_offset()
255 if (aarch64_insn_is_b(insn) || aarch64_insn_is_bl(insn)) in aarch64_set_branch_offset()
259 if (aarch64_insn_is_cbz(insn) || aarch64_insn_is_cbnz(insn) || in aarch64_set_branch_offset()
[all …]
A Dlivepatch.c20 uint32_t insn; in arch_livepatch_apply() local
41 insn = aarch64_insn_gen_nop(); in arch_livepatch_apply()
51 *(new_ptr + i) = insn; in arch_livepatch_apply()
159 u32 insn = *(u32 *)dest; in reloc_insn_movw() local
171 insn &= ~(3 << 29); in reloc_insn_movw()
175 insn |= 2 << 29; in reloc_insn_movw()
190 insn = aarch64_insn_encode_immediate(AARCH64_INSN_IMM_16, insn, imm); in reloc_insn_movw()
191 *(u32 *)dest = insn; in reloc_insn_movw()
204 u32 insn = *(u32 *)dest; in reloc_insn_imm() local
215 insn = aarch64_insn_encode_immediate(imm_type, insn, imm); in reloc_insn_imm()
[all …]
A DMakefile9 obj-y += insn.o
/xen/xen/include/asm-arm/arm32/
A Dinsn.h21 int32_t aarch32_get_branch_offset(uint32_t insn);
22 uint32_t aarch32_set_branch_offset(uint32_t insn, int32_t offset);
25 static inline bool insn_is_branch_imm(uint32_t insn) in insn_is_branch_imm() argument
50 return ( (insn & 0x0E000000) == 0x0A000000 ); in insn_is_branch_imm()
53 static inline int32_t insn_get_branch_offset(uint32_t insn) in insn_get_branch_offset() argument
55 return aarch32_get_branch_offset(insn); in insn_get_branch_offset()
58 static inline uint32_t insn_set_branch_offset(uint32_t insn, int32_t offset) in insn_set_branch_offset() argument
60 return aarch32_set_branch_offset(insn, offset); in insn_set_branch_offset()
/xen/xen/include/asm-arm/arm64/
A Dinsn.h72 bool aarch64_insn_is_branch_imm(u32 insn);
74 u64 aarch64_insn_decode_immediate(enum aarch64_insn_imm_type type, u32 insn);
76 u32 insn, u64 imm);
78 s32 aarch64_get_branch_offset(u32 insn);
79 u32 aarch64_set_branch_offset(u32 insn, s32 offset);
87 static inline bool insn_is_branch_imm(u32 insn) in insn_is_branch_imm() argument
89 return aarch64_insn_is_branch_imm(insn); in insn_is_branch_imm()
92 static inline s32 insn_get_branch_offset(u32 insn) in insn_get_branch_offset() argument
94 return aarch64_get_branch_offset(insn); in insn_get_branch_offset()
97 static inline u32 insn_set_branch_offset(u32 insn, s32 offset) in insn_set_branch_offset() argument
[all …]
/xen/xen/arch/arm/arm32/
A Dinsn.c26 static uint32_t branch_insn_encode_immediate(uint32_t insn, int32_t offset) in branch_insn_encode_immediate() argument
39 insn &= ~(BRANCH_INSN_IMM_MASK << BRANCH_INSN_IMM_SHIFT); in branch_insn_encode_immediate()
40 insn |= imm; in branch_insn_encode_immediate()
42 return insn; in branch_insn_encode_immediate()
50 int32_t aarch32_get_branch_offset(uint32_t insn) in aarch32_get_branch_offset() argument
55 imm = ( insn >> BRANCH_INSN_IMM_SHIFT ) & BRANCH_INSN_IMM_MASK; in aarch32_get_branch_offset()
71 uint32_t aarch32_set_branch_offset(uint32_t insn, int32_t offset) in aarch32_set_branch_offset() argument
81 return branch_insn_encode_immediate(insn, offset); in aarch32_set_branch_offset()
A Dlivepatch.c16 uint32_t insn; in arch_livepatch_apply() local
21 BUILD_BUG_ON(ARCH_PATCH_INSN_SIZE != sizeof(insn)); in arch_livepatch_apply()
54 insn = 0xea000000 | delta; in arch_livepatch_apply()
57 insn = 0xe1a00000; /* mov r0, r0 */ in arch_livepatch_apply()
64 *(new_ptr + i) = insn; in arch_livepatch_apply()
A DMakefile7 obj-y += insn.o
/xen/xen/arch/arm/
A Dalternative.c71 u32 insn; in get_alt_insn() local
73 insn = le32_to_cpu(*altinsnptr); in get_alt_insn()
75 if ( insn_is_branch_imm(insn) ) in get_alt_insn()
77 s32 offset = insn_get_branch_offset(insn); in get_alt_insn()
90 insn = insn_set_branch_offset(insn, offset); in get_alt_insn()
94 return insn; in get_alt_insn()
107 uint32_t insn; in patch_alternative() local
109 insn = get_alt_insn(alt, origptr + i, replptr + i); in patch_alternative()
110 updptr[i] = cpu_to_le32(insn); in patch_alternative()
A Dmm.c1323 uint32_t insn; in free_init_memory() local
1324 unsigned int i, nr = len / sizeof(insn); in free_init_memory()
1341 insn = 0xe7f000f0; in free_init_memory()
1343 insn = AARCH64_BREAK_FAULT; in free_init_memory()
1347 *(p + i) = insn; in free_init_memory()
/xen/tools/fuzz/x86_instruction_emulator/
A DMakefile4 .PHONY: x86-insn-fuzz-all
6 x86-insn-fuzz-all: x86-insn-fuzzer.a fuzz-emul.o afl
8 x86-insn-fuzz-all:
39 x86-insn-fuzzer.a: fuzz-emul.o x86-emulate.o cpuid.o
50 all: x86-insn-fuzz-all
/xen/xen/include/asm-x86/
A Dindirect_thunk_asm.h16 .macro INDIRECT_BRANCH insn:req arg:req
29 \insn __x86_indirect_thunk_r\reg
40 \insn *\arg
A Dalternative-asm.h39 #define decl_orig(insn, padding) \ argument
40 .L\@_orig_s: insn; .L\@_orig_e: \
49 #define decl_repl(insn, nr) .L\@_repl_s\()nr: insn; .L\@_repl_e\()nr: argument
A Dvm_event.h33 struct vm_event_emul_insn_data insn; member
/xen/xen/arch/x86/
A Dlivepatch.c129 uint8_t insn[sizeof(func->opaque)]; in arch_livepatch_apply() local
144 insn[0] = 0xe9; /* Relative jump. */ in arch_livepatch_apply()
147 memcpy(&insn[1], &val, sizeof(val)); in arch_livepatch_apply()
150 add_nops(insn, len); in arch_livepatch_apply()
152 memcpy(old_ptr, insn, len); in arch_livepatch_apply()
A Dvm_event.c284 v->arch.vm_event->emul.insn = rsp->data.emul.insn; in vm_event_emulate_check()
A Dxstate.c396 #define _xrstor(insn) \ in xrstor() argument
397 asm volatile ( "1: .byte " insn "\n" \ in xrstor()
/xen/xen/scripts/
A DKbuild.include29 # as-insn: Check whether assembler supports an instruction.
30 # Usage: cflags-y += $(call as-insn,CC FLAGS,"insn",option-yes,option-no)
31 as-insn = $(if $(shell echo 'void _(void) { asm volatile ( $(2) ); }' \
36 # Usage: $(call as-option-add,CFLAGS,CC,"insn",option-yes,option-no)
39 ifeq ($$(call as-insn,$$($(2)) $$($(1)),$(3),y,n),y)
/xen/tools/tests/x86_emulator/
A Dsimd.h204 # define REN(insn, old, new) \ argument
205 asm ( ".macro v" #insn #old " o:vararg \n\t" \
206 "v" #insn #new " \\o \n\t" \
A Dtest_x86_emulator.c1781 #define put_insn(which, insn) ".pushsection .test\n" \ in main() argument
1782 #which ": " insn "\n" \ in main()
/xen/xen/
A DMakefile139 t1 = $(call as-insn,$(CC),".L0: .L1: .skip (.L1 - .L0)",,-no-integrated-as)
142 t2 = $(call as-insn,$(CC) -I$(BASEDIR)/include,".include \"asm-x86/indirect_thunk_asm.h\"",,-no-int…
146 t3 = $(call as-insn,$(CC),".macro FOO;.endm"$(close); asm volatile $(open)".macro FOO;.endm",-no-in…
/xen/xen/include/public/
A Dvm_event.h397 struct vm_event_emul_insn_data insn; member
/xen/xen/test/livepatch/
A DMakefile198 CODE_GET_EXPECT=$(shell $(OBJDUMP) -d --insn-width=1 $(1) | sed -n -e '/<'$(2)'>:$$/,/^$$/ p' | tai…
/xen/xen/arch/x86/hvm/
A Demulate.c2792 sizeof(curr->arch.vm_event->emul.insn.data)); in hvm_emulate_one_vm_event()
2800 memcpy(vio->mmio_insn, curr->arch.vm_event->emul.insn.data, in hvm_emulate_one_vm_event()

Completed in 57 milliseconds