Re: [PATCH v2] target/arm/arch_dump: Add SVE notes

2019-10-16 Thread Richard Henderson
On 10/16/19 2:13 AM, Andrew Jones wrote: > On Thu, Oct 10, 2019 at 01:33:02PM -0400, Richard Henderson wrote: >> Ah, I wonder if you changed things around with the ifdefs due to the pregs. >> There's no trivial solution for those. It'd be nice to share the bswapping >> subroutine that you add in t

Re: [PATCH v2] target/arm/arch_dump: Add SVE notes

2019-10-16 Thread Andrew Jones
On Thu, Oct 10, 2019 at 01:33:02PM -0400, Richard Henderson wrote: > On 10/10/19 2:16 AM, Andrew Jones wrote: > >> It might be best to avoid the ifdef altogether: > >> > >> for (i = 0; i < 32; ++i) { > >> uint64_t *d = (uint64_t *)&buf[sve_zreg_offset(vq, i)]; > >> for (j = 0; j

Re: [PATCH v2] target/arm/arch_dump: Add SVE notes

2019-10-10 Thread Richard Henderson
On 10/10/19 2:16 AM, Andrew Jones wrote: >> It might be best to avoid the ifdef altogether: >> >> for (i = 0; i < 32; ++i) { >> uint64_t *d = (uint64_t *)&buf[sve_zreg_offset(vq, i)]; >> for (j = 0; j < vq * 2; ++j) { >> d[j] = cpu_to_le64(env->vfp.zregs[i].d[j]); >>

Re: [PATCH v2] target/arm/arch_dump: Add SVE notes

2019-10-09 Thread Andrew Jones
On Wed, Oct 09, 2019 at 08:39:21PM -0400, Richard Henderson wrote: > On 10/4/19 8:03 AM, Andrew Jones wrote: > > +#ifdef TARGET_AARCH64 > > +static off_t sve_zreg_offset(uint32_t vq, int n) > > +{ > > +off_t off = sizeof(struct aarch64_user_sve_header); > > +return ROUND_UP(off, 16) + vq *

Re: [PATCH v2] target/arm/arch_dump: Add SVE notes

2019-10-09 Thread Richard Henderson
On 10/4/19 8:03 AM, Andrew Jones wrote: > +#ifdef TARGET_AARCH64 > +static off_t sve_zreg_offset(uint32_t vq, int n) > +{ > +off_t off = sizeof(struct aarch64_user_sve_header); > +return ROUND_UP(off, 16) + vq * 16 * n; > +} > +static off_t sve_preg_offset(uint32_t vq, int n) > +{ > +re

Re: [PATCH v2] target/arm/arch_dump: Add SVE notes

2019-10-04 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20191004120313.5347-1-drjo...@redhat.com/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20191004120313.5347-1-drjo...@redhat.com Subject: [PATCH v2] target/arm/arch_dump: Add SVE

[PATCH v2] target/arm/arch_dump: Add SVE notes

2019-10-04 Thread Andrew Jones
When dumping a guest with dump-guest-memory also dump the SVE registers if they are in use. Signed-off-by: Andrew Jones --- include/elf.h | 2 + target/arm/arch_dump.c | 135 - 2 files changed, 135 insertions(+), 2 deletions(-) diff --git a/inc