Re: Variable scope debug info

2007-04-07 Thread Robert Dewar
Rob Quill wrote: OK, that sounds good to me. As you say, there is no way to know until it is actually implemented how muh affect it will have. However, I won't be able to start on it until summer as I have to worry about sitting my finals, so I'll let you know when I get started. I would say t

Re: Variable scope debug info

2007-04-07 Thread Rob Quill
On 06/04/07, Joe Buck <[EMAIL PROTECTED]> wrote: On Fri, Apr 06, 2007 at 11:38:50AM +0100, Rob Quill wrote: > So the general concensus is that's it's not worth doing? > Hypothetically, if I did it and it didn't make much difference, would > it be worth submitting a patch? Or should I just give up

Re: Variable scope debug info

2007-04-06 Thread Pedro Alves
Joe Buck wrote: It might be worth doing. I think that, in addition to a patch, I'd like to see measurements (maybe just the size increase in libstdc++.{a,so}). If the cost is small, I will not object. If the cost turns out non-small, this could be enabled at -g3? Cheers, Pedro Alves

Re: Variable scope debug info

2007-04-06 Thread Joe Buck
On Fri, Apr 06, 2007 at 11:38:50AM +0100, Rob Quill wrote: > So the general concensus is that's it's not worth doing? > Hypothetically, if I did it and it didn't make much difference, would > it be worth submitting a patch? Or should I just give up before I > start? It might be worth doing. I thi

Re: Variable scope debug info

2007-04-06 Thread Joe Buck
On Fri, Apr 06, 2007 at 11:50:01AM +0100, Rob Quill wrote: > >int i = 0; > >int j = 2; > >int n = CalculateSomething( j, &i ); > >int k = 3; > > I don't really understand, because the problem remains that if you > break before int n... and do print n you get a value, whereas you > should get an er

Re: Variable scope debug info

2007-04-06 Thread Brian Ellis
> On 05/04/07, Brian Ellis <[EMAIL PROTECTED]> wrote: > > > > Now if there were actual function calls in the initialization, and no > > records were emitted, I would consider that to be a problem (haven't tested > > this at the moment though), however, static initializers like that could > > eas

Re: Variable scope debug info

2007-04-06 Thread Rob Quill
lopment Sent: Thursday, April 5, 2007 12:32:04 PM Subject: Re: Variable scope debug info On Thu, Apr 05, 2007 at 02:37:06PM +0100, Rob Quill wrote: > My problem is thus: When using GDB do debug the follow bit of code: > > int i = 0; > int j = 2; > int k = 3; > > If I set a br

Re: Variable scope debug info

2007-04-06 Thread Rob Quill
So the general concensus is that's it's not worth doing? Hypothetically, if I did it and it didn't make much difference, would it be worth submitting a patch? Or should I just give up before I start? Rob On 06/04/07, Daniel Jacobowitz <[EMAIL PROTECTED]> wrote: On Thu, Apr 05, 2007 at 09:46:18A

Re: Variable scope debug info

2007-04-05 Thread Daniel Jacobowitz
On Thu, Apr 05, 2007 at 09:46:18AM -0700, Joe Buck wrote: > Now, it might turn out that adding additional dwarf records for > every single declaration won't significantly increase the size > of the debug information. But it is a consideration. FWIW, I would expect that it would not make a signifi

Re: Variable scope debug info

2007-04-05 Thread Mike Stump
On Apr 5, 2007, at 9:46 AM, Joe Buck wrote: The test/debug/recompile loop I spend much of my life in lately is dominated by link time. We found that omitting the debug information from the link step solves this issue.

Re: Variable scope debug info

2007-04-05 Thread Joe Buck
On Thu, Apr 05, 2007 at 10:21:28AM -0700, Brian Ellis wrote: > Now if there were actual function calls in the initialization, and no > records were emitted, I would consider that to be a problem (haven't > tested this at the moment though), however, static initializers like > that could easily be

Re: Variable scope debug info

2007-04-05 Thread Brian Ellis
ll <[EMAIL PROTECTED]> Cc: GCC Development Sent: Thursday, April 5, 2007 12:32:04 PM Subject: Re: Variable scope debug info On Thu, Apr 05, 2007 at 02:37:06PM +0100, Rob Quill wrote: > My problem is thus: When using GDB do debug the follow bit of code: > > int i = 0; > int j = 2; &g

Re: Variable scope debug info

2007-04-05 Thread Joe Buck
I wrote: > >If adding scope attributes every time more than one variable is declared > >adds to the already immense bulk of C++ debugging information, I'd > >prefer to live with the bug myself. On Thu, Apr 05, 2007 at 05:36:57PM +0100, Rob Quill wrote: > Out of interest, why? I haven't looked int

Re: Variable scope debug info

2007-04-05 Thread Rob Quill
On 05/04/07, Joe Buck <[EMAIL PROTECTED]> wrote: On Thu, Apr 05, 2007 at 02:37:06PM +0100, Rob Quill wrote: > My problem is thus: When using GDB do debug the follow bit of code: > > int i = 0; > int j = 2; > int k = 3; > > If I set a breakpoint at the 3rd line, before int k = 3; has been > execut

Re: Variable scope debug info

2007-04-05 Thread Joe Buck
On Thu, Apr 05, 2007 at 02:37:06PM +0100, Rob Quill wrote: > My problem is thus: When using GDB do debug the follow bit of code: > > int i = 0; > int j = 2; > int k = 3; > > If I set a breakpoint at the 3rd line, before int k = 3; has been > executed, and check if k is in scope, I find that it is

Re: Variable scope debug info

2007-04-05 Thread Ian Lance Taylor
"Rob Quill" <[EMAIL PROTECTED]> writes: > My problem is thus: When using GDB do debug the follow bit of code: > > int i = 0; > int j = 2; > int k = 3; > > If I set a breakpoint at the 3rd line, before int k = 3; has been > executed, and check if k is in scope, I find that it is, when, of > cours