ddd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Plotting large arrays


From: Atwood, Robert C
Subject: Plotting large arrays
Date: Thu, 15 Jul 2004 13:20:27 +0100


Zbyszek:

I believe this is simply due the default setting of print elements in
gdb.
Please refer to the GDB manual also, (assuming you are using gdb as the
underlying debugger) There are lots of settings ...

If this is not the cause of your problem, you should post a specific
example of what you mean. I used the code below (testarray.c) ,
displaying 

address@hidden 

at a break point at line 9. (using 'graph display address@hidden', then
highlighting the display and choosing the 'plot' button)


      1 int main(){
      2  int * a;
      3  int i;
      4  a=(int *)malloc(4000 * sizeof(int));
      5    for (i=0;i<4000;i++){
      6      *(a+i) = i;
      7    }
      8
      9  printf("all full\n");
     10  free(a);
     11 }

>From the gdb manual:

*************************
set print elements number-of-elements 
     Set a limit on how many elements of an array GDB will print. If GDB
is printing a large array, it stops printing after it has printed the
number of elements set by the set print
     elements command. This limit also applies to the display of
strings. When GDB starts, this limit is set to 200. Setting
number-of-elements to zero means that the printing is unlimited. 
*************************

(also accessible on the Gdb-settings menu)


I notice that the data-graph display gets some "vsl errors" if this is
increased to 4000 , and the display just shows 

<?vertical_array> 

, but the plot seems to work, maybe if you choose appropriate display
settings this behaviour can be avoided?
Once the display is created the first time, it seems that if I try
'disabling' the display, the plot works in any case but the display
errors are avoided. I am not sure how to create the display already
disabled, to avoid the error messages (and slow response during the
error messages) -- anyone els know how to do this?



Hope this helps
Robert



-----Original Message-----
From: Zbyszek P. Karkuszewski [mailto:address@hidden 
Sent: 15 July 2004 06:45
To: Atwood, Robert C
Subject: Re: FW: DDD 3.3.9 (i686-pld-linux-gnu) gets `BadWindow' error


Hi,

I have tryied this trick but for some reasons couldn't plot my full 4000
elements matrix. Only a small part of the matrix was showing up in the
gnuplot window.

Cheers!
zbyszek

> Not sure if you saw this other workaround, it is even easier and you 
> can keep 4.0 gnuplot with ddd
> 
> Also this info. may help find what the problem is.
> 
> 
> 
> -----Original Message-----
> From: address@hidden
> [mailto:address@hidden On Behalf Of Joby

> Joseph
> Sent: 14 July 2004 10:43
> To: address@hidden
> Subject: Re: DDD 3.3.9 (i686-pld-linux-gnu) gets `BadWindow' error
> 
> 
> In     Edit->Preferences->Helpers
>    set Plot window to be 'Externel' . This is not a correct fix but a
> workaround for now.
>       joby
> 
> 
> On Wednesday 14 July 2004 06:44, Zbyszek P. Karkuszewski wrote:
> > Hi,
> >
> > When I try to plot elements of matrix phi it takes forever to start
> > gnuplot and when I click Cancel button on this little pop-up window 
> > that says that gnuplot is being started ddd kicks the bucked and 
> > reports that I had found a bug.
> >
> > log file is attached.
> >
> > Cheers!
> > zbyszek
> 
> --
> Joby Joseph
> SSP Lab, Acoustic Bldg.      Phone : +91 80 2293 2280
> Department of ECE            Email : address@hidden
> Indian Institute of Science          address@hidden
> Bangalore 560 012            URL   :
> http://www.dsp.ece.iisc.ernet.in/~joby/
> India
> 
> 
> 
> _______________________________________________
> Ddd mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/ddd




reply via email to

[Prev in Thread] Current Thread [Next in Thread]