Joel Brobecker | 1 Jan 2010 04:35
Favicon

Re: patch for testing purposes

> i accidentally reversed the source and destination source files,
> here it is again.

Ah, ok! :). 

I am sorry if I am repeating the same things, but you forgot to use
-up when generating the patch...  Have you also had the chance to
read the CONTRIBUTE file? The ChangeLog entry is still missing too.
A little word of introduction to explain what you are trying to do
and why would have been helpful as well.

> < /* Print the status word STATUS.  */
> < 
> < static void
> < print_i387_status_word (unsigned int status, struct ui_file *file)
> ---
> > // print the status word
> > // updated 20091231 (development <at> codenamezero.org)

We do not use C++-style comments in the GDB code, because GDB is
supposed to be buildable with non-GCC compilers supporting ISO C90.
Also, the the "updated 20091231 (development <at> codenamezero.org)" is
superfluous and should go.

> <   fprintf_filtered (file, "Status Word:         %s",
> < 		    hex_string_custom (status, 4));
> <   fputs_filtered ("  ", file);
> <   fprintf_filtered (file, " %s", (status & 0x0001) ? "IE" : "  ");

It looks like you changed the indentation of the code. This is not
(Continue reading)

Joel Brobecker | 1 Jan 2010 04:56
Favicon

Re: [patch] testsuite: false MI "unknown output after running" regression

> gdb/testsuite/
> 2009-12-31  Jan Kratochvil  <jan.kratochvil <at> redhat.com>
> 
> 	* lib/mi-support.exp (mi_expect_stop <stopped at wrong place>): Insert
> 	missing $after_stopped and comma (,) expectation.

Phew, it took me a long time to understand how this patch could fix
the bad regexp on some of the examples you provided (the after_stop
field is empty), because I failed to notice that you added the missing
comma.

This looks right to me. Please go ahead an apply (I will rotate the
ChangeLog et al in a moment).

--

-- 
Joel

Joel Brobecker | 1 Jan 2010 07:31
Favicon

[commit] Fix "break *EXP thread/task NUM" for Ada (was: "Re: RFC: Fix "break *EXP thread NUM"")

I finally took the time to fix this for Ada as well.  Initially,
I just fixed it for "task", until I realized that I should have
fixed it for both "thread" and "task". Hence two patches instead
of just one.

2010-01-01  Joel Brobecker  <brobecker <at> adacore.com>

        Fix break *FUN'address task NUM.
        * ada-lex.l (task): New rule.
        * ada-lang.c (valid_task_id): Make sure the Ada task list has
        been built before using it.

2010-01-01  Joel Brobecker  <brobecker <at> adacore.com>

        Fix break *FUN'address thread NUM.
        * ada-lex.l (task): Expand rule to also match the thread keyword.

Tested on x86_64-linux.

--

-- 
Joel
Attachment (task-bp-at-addr.diff): text/x-diff, 1020 bytes
Attachment (thread-bp-at-addr.diff): text/x-diff, 691 bytes
Michael | 1 Jan 2010 08:12

Re: patch for testing purposes

Joel,

Here it is again. For your information, I added a few lines of code to 
the 'info float' statement. Hope you like them :)

Happy new year,
Michael

Joel Brobecker wrote:
>> i accidentally reversed the source and destination source files,
>> here it is again.
>>     
>
> Ah, ok! :). 
>
> I am sorry if I am repeating the same things, but you forgot to use
> -up when generating the patch...  Have you also had the chance to
> read the CONTRIBUTE file? The ChangeLog entry is still missing too.
> A little word of introduction to explain what you are trying to do
> and why would have been helpful as well.
>
>   
>> < /* Print the status word STATUS.  */
>> < 
>> < static void
>> < print_i387_status_word (unsigned int status, struct ui_file *file)
>> ---
>>     
>>> // print the status word
>>> // updated 20091231 (development <at> codenamezero.org)
(Continue reading)

Jan Kratochvil | 1 Jan 2010 09:02
Picon
Favicon

Re: [patch] testsuite: false MI "unknown output after running" regression

On Fri, 01 Jan 2010 04:56:39 +0100, Joel Brobecker wrote:
> Phew, it took me a long time to understand how this patch could fix
> the bad regexp on some of the examples you provided (the after_stop
> field is empty), because I failed to notice that you added the missing
> comma.

Sorry I forgot to include the originally intended wdiff of this patch of mine.

	-re
"\\*stopped,${r}${a}${bn}frame=\{addr=\"$hex\",func=\"$any\",args=\[\\\[\{\]$any\[\\\]\}\],file=\"$any\",fullname=\"${fullname_syntax}$any\",line=\"\[0-9\]*\"\}{+$after_stopped,+}thread-id=\"$decimal\",stopped-threads=$any\r\n$prompt_re" {

> This looks right to me. Please go ahead an apply (I will rotate the
> ChangeLog et al in a moment).

Checked-in already with 2010-01-01 (after an IRC approval).

Thanks,
Jan

http://sourceware.org/ml/gdb-cvs/2010-01/msg00010.html

--- src/gdb/testsuite/ChangeLog	2009/12/31 17:47:42	1.2060
+++ src/gdb/testsuite/ChangeLog	2010/01/01 07:57:56	1.2061
 <at>  <at>  -1,3 +1,8  <at>  <at> 
+2010-01-01  Jan Kratochvil  <jan.kratochvil <at> redhat.com>
+
+	* lib/mi-support.exp (mi_expect_stop <stopped at wrong place>): Insert
+	missing $after_stopped and comma (,) expectation.
+
 2009-12-31  Stan Shebs  <stan <at> codesourcery.com>
(Continue reading)

Joel Brobecker | 1 Jan 2010 09:06
Favicon

2010 Start of New Year procedure applied...

... or almost!

I've applied the Start of New Year procedure as outlined in our GDB
Internals Manual, including updating the copyright header of most
source files (the ones covered by copyright.sh). And I also updated
the copyright years of all .texi* files manually (patch not attached).

2010-01-01  Joel Brobecker  <brobecker <at> adacore.com>

        * top.c (print_gdb_version): Update copyright year.

2010-01-01  Joel Brobecker  <brobecker <at> adacore.com>

        * server.c (gdbserver_version): Update copyright year to 2010.
        * gdbreplay.c (gdbreplay_version): Likewise.

2010-01-01  Joel Brobecker  <brobecker <at> adacore.com>

        * agentexpr.texi: Add 2010 to the list of copyright years.
        * annotate.texinfo: Likewise.
        * gdb.texinfo: Likewise.
        * gdbint.texinfo: Likewise.
        * observer.texi: Likewise.
        * stabs.texinfo: Likewise.

--

-- 
Joel
Attachment (top.c.diff): text/x-diff, 665 bytes
Attachment (gdbserver-copyright.diff): text/x-diff, 1308 bytes
(Continue reading)

Joel Brobecker | 1 Jan 2010 09:18
Favicon

Re: patch for testing purposes

> Here it is again. For your information, I added a few lines of code
> to the 'info float' statement. Hope you like them :)

You are going to hate me, but it's still not right. Sorry!

How are you generating your diff? From the markers in the diff patch,
it looks like you generated it without the assistance of a version-control
system.  You are making things harder for you because you have to make sure
that the tree that you use as a reference matches exactly what you started
from.  Otherwise, you end up with differences that should not be in
 the patch, as you are seeing at least in your patch to the ChangeLog file.

I strongly recommend that you start the safest way: Checkout the sources
from either CVS or git, apply your changes to these sources, and then
use either CVS or git to generate the diff (either "cvs diff -up" or
"git diff").  I would both sending a diff to the ChangeLog file but
simply put the ChangeLog entry in the email body.  You can have a look
at previous messages sent to this mailing-list as a guideline. Please
verify that the patch you are sending corresponds exactly to the changes
you made, no more, no less.

Please also make sure to say that you did change your test by running
the testsuite before and after your change, comparing the results,
and on which platform.  I can help walking you through this process
if you need help.  But first, let's make sure you know how to generate
the patch properly, and that you know how to present them to this
mailing-list.

I hope you're not feeling discouraged. This is only a matter of learning
the procedure, and once you know it, you won't have to go through this
(Continue reading)

Jan Kratochvil | 1 Jan 2010 09:40
Picon
Favicon

[patch] Fix crash on CLI indented comments [Re: [Bug:cli] Loading user-defined function generates an internal error]

On Wed, 30 Dec 2009 23:26:27 +0100, Nick Roberts wrote:
> Heres a simpler user defined function that gives a segmentation fault.  It
> appears that GDB can no longer handle indented comments.
> 
> define my_fun
>  #indented comment
> end

      (*command)->line = savestring (p, p1 - p);
#1  0x0000000000487405 in savestring (ptr=0x1d5dd31 "", size=18446744073709551615) at utils.c:1377
(gdb) p/x size
$1 = 0xffffffffffffffff
(gdb) p p
$2 = 0x1d5dd31 ""
(gdb) p p1
$3 = 0x1d5dd30 " "

OK to check-in? Probably [obv].

Thanks,
Jan

2010-01-01  Jan Kratochvil  <jan.kratochvil <at> redhat.com>

	* cli/cli-script.c (process_next_line): Check P2 overrun.

--- a/gdb/cli/cli-script.c
+++ b/gdb/cli/cli-script.c
 <at>  <at>  -893,7 +893,7  <at>  <at>  process_next_line (char *p, struct command_line **command, int parse_commands)

(Continue reading)

Jan Kratochvil | 1 Jan 2010 09:43
Picon
Favicon

[patch] Rename process_next_line variables

Hi,

just a simple %s, it is a patch on top of:
	[patch] Fix crash on CLI indented comments [Re: [Bug:cli] Loading user-defined function generates an
internal error]
	http://sourceware.org/ml/gdb-patches/2010-01/msg00007.html

Nothing important, np to drop it.

Thanks,
Jan

2010-01-01  Jan Kratochvil  <jan.kratochvil <at> redhat.com>

	* cli/cli-script.c (process_next_line): Rename p1 as p_end and p2 as
	p_start.

--- ./gdb/cli/cli-script.c-p0	2010-01-01 09:31:38.000000000 +0100
+++ ./gdb/cli/cli-script.c	2010-01-01 09:33:30.000000000 +0100
 <at>  <at>  -878,8 +878,8  <at>  <at>  read_next_line ()
 static enum misc_command_type
 process_next_line (char *p, struct command_line **command, int parse_commands)
 {
-  char *p1;
-  char *p2;
+  char *p_end;
+  char *p_start;
   int not_handled = 0;

   /* Not sure what to do here.  */
(Continue reading)

Jan Kratochvil | 1 Jan 2010 09:46
Picon
Favicon

Re: [patch] Rename process_next_line variables

On Fri, 01 Jan 2010 09:43:32 +0100, Jan Kratochvil wrote:
2010-01-01  Jan Kratochvil  <jan.kratochvil <at> redhat.com>

	* cli/cli-script.c (process_next_line): Rename p1 as p_end and p2 as
	p_start.  Change != comparisons to > and < comparisons.

Updated the ChangeLog entry.

Sorry,
Jan

> -  while (p1 != p && (p1[-1] == ' ' || p1[-1] == '\t'))
> +  while (p_end > p && (p_end[-1] == ' ' || p_end[-1] == '\t'))

> -  while (p2 != p1 && (*p2 == ' ' || *p2 == '\t'))
> +  while (p_start < p_end && (*p_start == ' ' || *p_start == '\t'))


Gmane