This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Negative repeat count for 'x' command
- From: Toshihito Kikuchi <k dot toshihito at yahoo dot de>
- To: Pedro Alves <palves at redhat dot com>, gdb-patches at sourceware dot org
- Cc: Paul_Koning at Dell dot com, andrew dot burgess at embecosm dot com, jhb at freebsd dot org
- Date: Thu, 28 Apr 2016 11:05:28 -0700
- Subject: Re: [PATCH] Negative repeat count for 'x' command
- Authentication-results: sourceware.org; auth=none
- References: <F83BD80E-E1AA-4C1E-86BB-9A995B831256 at dell dot com> <1095889805 dot 138513 dot 1453786618993 dot JavaMail dot yahoo at mail dot yahoo dot com> <20160127160420 dot GM3338 at embecosm dot com> <AF6EBE4A-8B9B-4AB4-80D2-A38662F36F4A at dell dot com> <56AA013F dot 8010601 at redhat dot com> <56B7D0E3 dot 8020402 at yahoo dot de> <570B95AE dot 80406 at redhat dot com> <571035CC dot 7060802 at yahoo dot de> <5714DE73 dot 5010104 at redhat dot com>
Hi Pedro,
I've sent V3 patch today.
> BTW, aren't these tests dependent on the host's charset? (show host-charset)
Thank you for pointing this out. Yes, then I added 'set host-charset ASCII'
before running string testcases.
> An idea to generalize the x/i tests to all archs would be to
> let go of the asm, and instead write the test function in C. Then
> you'd first use forward x/i to store a few line's instructions in
> a list/array, and afterwards you'd disassemble backwards, comparing
> with the expected instructions stored in the stored list/array.
> I wonder whether that'd work.
This was great suggestion. I realized .exp test scripts can support complex
logics more than expected. I added a new section 'backward disassemble general'
to do that.
A new section "address zero boundary" is also added to test around address zero.
Since I don't have non-MMU machines, I verified it using by setting
/proc/sys/vm/mmap_min_addr to 0.
Thanks,
Toshihito