Re: segmentation fault




The code's pretty big to be posted here. I am using g95 compiler, and I
just posted last few lines of the code and the corresponding o/p.


Steven G. Kargl wrote:
> In article <1135406189.209378.79820@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
> "student" <adarsh@xxxxxxxxxxxxx> writes:
> > I have two codes in f90 which do exactly the same things. The only
> > differences between the two codes is that in one case I declared the
> > exact sizes of the arrays and in the other case, I declared each array
> > to be an allocatable array and then later allocated their sizes. The
> > answers that I get from the two codes are exactly the same too.
> > However, for some reason the latter code gives a segmentation fault
> > error while quitting. Can anyone point out what's happening here.
>
> You left out most of the important information! What OS?
> What compiler or compilers are you using? What compiler
> options? Have you used an array bounds checking option?
> Most importantly you left out the code or a URL to the
> code.
>
> --
> Steve
> http://troutmask.apl.washington.edu/~kargl/

.



Relevant Pages

  • Re: Idea for ECMA/C# Standard - compile time hash for performance
    ... I agree with you the chance of a compiler change is slim, ... and then delegating to the standard hash for fields accessed less frequently. ... or the array lookup which would require the ... > 64-bit architecture) for each enum value that doesn't map to anything. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Q: Checking the size of a non-allocated array?
    ... an actual argument is already invalid ... First note that you don't have an unallocated array in the subroutine. ... it is comparable to disassociated or undefined pointers. ... Obviously the compiler has ...
    (comp.lang.fortran)
  • Re: Windows array allocation problem
    ... array reference has to have a 64-bit index or array subscript triplet? ... to fit in one. ... That assumes, of course, that your compiler ... limits on just about anything. ...
    (comp.lang.fortran)
  • Bounds checked arrays
    ... As everybody knows, the C language lacks ... When the state of this toggle is ON, the compiler ... Important is to know that the array updates ... We have just to allow him/her to specify what to do ...
    (comp.lang.c)
  • Re: Error handling library
    ... which lets the compiler catch out-of-range usage. ... and assuming that a higher int means "more dangerous error" ... with a comment warning that one is used as an index into the array ... languages while running (an array of languages, ...
    (comp.lang.c)