This is the mail archive of the gsl-discuss@sources.redhat.com mailing list for the GSL project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Memory!



Hi Brian!

I'm using the Sun cc and not gcc. Because of the XForms, I cannot compile
my program with gcc and if I try it, then I get a lot of error messages
and no executable. How kann I check memory accesses without checkergcc?

I'm using gsl_multiroot subroutines in the following form:

F.f = &function; 
F.n = 2;
F.params = 0; 

and then I got by compiling with cc such warnings:

./rootfinder.c", line 175: warning: assignment type mismatch:
        pointer to function(pointer to const struct gsl_vector_struct
{uint size, uint stride, pointer to double data, pointer to st... "="
pointer to function(pointer to struct gsl_vector_struct {uint size, uint
stride, pointer to double data, pointer to struct g...

I don't know if that could create memory problems!

Thanks in advance!

Greetings from katlenburg-Lindau!

Francisco 
Max Planck Institut fuer Aeronomie



 On Tue, 4 Jul 2000, Brian Gough wrote:

> You need to be careful about memory allocation when using GSL.
> 
> I recommend compiling your program and the library with "checkergcc",
> which automatically checks memory accesses for you. It is very useful.
> 
> Francisco Frutos writes:
>  > 
>  > Hi!
>  > 
>  > My code had an error. Now using 
>  > 
>  > gsl_siman_solve(r, x_init, Energy, Step, Metric, Print, M * N * 
>  > sizeof(double), params);
>  > 
>  > I get good values!
>  > 
>  > I'm using gsl_multiroot in my program too und my program crashed most of
>  > the time if I use both subroutines??? Do the gsl_siman_solve need one
>  > "gsl_free" for the memory or something like that?  
>  > 
>  > Thanks in advance!
>  > 
>  > Greetings from Katlenburg-Lindau!
>  > 
>  > Tschuessele!
>  > 
>  > Francisco
>  > Max Planck Institut fuer Aeronomie
>  > 
>  > 
> 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]