This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH v1 1/1] Fix PR16193 - gdbserver aborts.
- From: Pedro Alves <palves at redhat dot com>
- To: Walfred Tedeschi <walfred dot tedeschi at intel dot com>
- Cc: yao at codesourcery dot com, gdb-patches at sourceware dot org
- Date: Mon, 25 Nov 2013 15:01:26 +0000
- Subject: Re: [PATCH v1 1/1] Fix PR16193 - gdbserver aborts.
- Authentication-results: sourceware.org; auth=none
- References: <1385386802-16948-1-git-send-email-walfred dot tedeschi at intel dot com> <529363FF dot 3060602 at intel dot com>
On 11/25/2013 02:51 PM, Walfred Tedeschi wrote:
> Hello All,
>
> For clarification the macro I386_XSTATE_SIZE(XCR0) was returning for any
> XCR0 the value 576.
I must be very dense today, sorry. :-( Can you point out why that
was so before the patch, and no longer is so after the patch?
>> > /* Get I386 XSAVE extended state size. */
>> > #define I386_XSTATE_SIZE(XCR0) \
>> > - (((XCR0) & I386_XSTATE_BNDCFG) != 0 ? I386_XSTATE_BNDCFG_SIZE \
>> > - : (((XCR0) & I386_XSTATE_BNDREGS) != 0 ? I386_XSTATE_BNDCFG_SIZE \
>> > - : (((XCR0) & I386_XSTATE_AVX_SIZE) != 0 ? I386_XSTATE_AVX_SIZE \
>> > - : I386_XSTATE_SSE_SIZE)))
>> > + (HAS_MPX (XCR0) ? I386_XSTATE_BNDCFG_SIZE : \
>> > + (HAS_AVX (XCR0) ? I386_XSTATE_AVX_SIZE : I386_XSTATE_SSE_SIZE))
I'm unrolling the new macros in my head, and I can figure out why
does this now return a different value. :-/
--
Pedro Alves