From: Dmitry Selyutin Date: Tue, 11 Apr 2023 18:27:24 +0000 (+0300) Subject: ppc/svp64: support els specifier X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5d405ad1da4476eb0c2a8d952c678774c3fddd55;p=binutils-gdb.git ppc/svp64: support els specifier --- diff --git a/gas/config/tc-ppc-svp64.c b/gas/config/tc-ppc-svp64.c index f771151f088..1cab144ad6e 100644 --- a/gas/config/tc-ppc-svp64.c +++ b/gas/config/tc-ppc-svp64.c @@ -24,6 +24,9 @@ struct svp64_ctx { const char *name; const struct svp64_desc *desc; + unsigned int sv_mode_explicit : 1; + unsigned int sv_mode : 2; + unsigned int mode : 5; unsigned int pmmode : 1; unsigned int pmask : 3; unsigned int smmode : 1; @@ -35,6 +38,7 @@ struct svp64_ctx { unsigned int subvl : 2; unsigned int destwid : 2; unsigned int srcwid : 2; + unsigned int els : 1; }; static jmp_buf svp64_exception; @@ -336,6 +340,25 @@ svp64_decode_sw (char *str, struct svp64_ctx *svp64) return iter; } +static char * +svp64_decode_els (char *str, struct svp64_ctx *svp64) +{ + str += (sizeof ("els") - 1); + if ( ! ISSPACE (*str) && *str != SVP64_SEP && *str != '\0') + return NULL; + + svp64->els = 1; + if (svp64->desc->mode == SVP64_MODE_LDST_IDX) + { + svp64->sv_mode = 0x1; + svp64->sv_mode_explicit = 1; + } + + *str++ = '\0'; + + return str; +} + static char * svp64_decode_mode (char *str, struct svp64_ctx *svp64) { @@ -350,6 +373,7 @@ svp64_decode_mode (char *str, struct svp64_ctx *svp64) SVP64_DECODER ("w=" , svp64_decode_w), SVP64_DECODER ("dw=" , svp64_decode_dw), SVP64_DECODER ("sw=" , svp64_decode_sw), + SVP64_DECODER ("els" , svp64_decode_els), }; for (i = 0; i < sizeof (table) / sizeof (table[0]); ++i)