From 08895cda3a57fe2d72ef621800606ddc2f5eb612 Mon Sep 17 00:00:00 2001 From: Richard Henderson Date: Tue, 20 Oct 2020 21:51:35 -0700 Subject: qemu/int128: Add int128_or MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Richard Henderson Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Alex Bennée Message-Id: <20201021045149.1582203-2-richard.henderson@linaro.org> --- include/qemu/int128.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'include') diff --git a/include/qemu/int128.h b/include/qemu/int128.h index 76ea405..52fc238 100644 --- a/include/qemu/int128.h +++ b/include/qemu/int128.h @@ -58,6 +58,11 @@ static inline Int128 int128_and(Int128 a, Int128 b) return a & b; } +static inline Int128 int128_or(Int128 a, Int128 b) +{ + return a | b; +} + static inline Int128 int128_rshift(Int128 a, int n) { return a >> n; @@ -208,6 +213,11 @@ static inline Int128 int128_and(Int128 a, Int128 b) return (Int128) { a.lo & b.lo, a.hi & b.hi }; } +static inline Int128 int128_or(Int128 a, Int128 b) +{ + return (Int128) { a.lo | b.lo, a.hi | b.hi }; +} + static inline Int128 int128_rshift(Int128 a, int n) { int64_t h; -- cgit v1.1 From 560f5a10e85ef025ced5e8bb21c9bb1c8431dcd5 Mon Sep 17 00:00:00 2001 From: Taylor Simpson Date: Sun, 7 Feb 2021 23:45:53 -0600 Subject: Hexagon (include/elf.h) ELF machine definition MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Define EM_HEXAGON 164 Signed-off-by: Taylor Simpson Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-Id: <1612763186-18161-4-git-send-email-tsimpson@quicinc.com> Signed-off-by: Richard Henderson --- include/elf.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/elf.h b/include/elf.h index 7a418ee..f4fa3c1 100644 --- a/include/elf.h +++ b/include/elf.h @@ -176,6 +176,7 @@ typedef struct mips_elf_abiflags_v0 { #define EM_UNICORE32 110 /* UniCore32 */ +#define EM_HEXAGON 164 /* Qualcomm Hexagon */ #define EM_RX 173 /* Renesas RX family */ #define EM_RISCV 243 /* RISC-V */ -- cgit v1.1 From a00cfed0ed9c366a383fe39c2d283362ebaaefd3 Mon Sep 17 00:00:00 2001 From: Taylor Simpson Date: Sun, 7 Feb 2021 23:45:55 -0600 Subject: Hexagon (disas) disassembler MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add hexagon to disas/meson.build Add disas/hexagon.c Add hexagon to include/disas/dis-asm.h Signed-off-by: Taylor Simpson Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Message-Id: <1612763186-18161-6-git-send-email-tsimpson@quicinc.com> Signed-off-by: Richard Henderson --- include/disas/dis-asm.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/disas/dis-asm.h b/include/disas/dis-asm.h index d1133a4..13fa1ed 100644 --- a/include/disas/dis-asm.h +++ b/include/disas/dis-asm.h @@ -459,6 +459,7 @@ int print_insn_xtensa (bfd_vma, disassemble_info*); int print_insn_riscv32 (bfd_vma, disassemble_info*); int print_insn_riscv64 (bfd_vma, disassemble_info*); int print_insn_rx(bfd_vma, disassemble_info *); +int print_insn_hexagon(bfd_vma, disassemble_info *); #ifdef CONFIG_CAPSTONE bool cap_disas_target(disassemble_info *info, uint64_t pc, size_t size); -- cgit v1.1