Re: [Rd] A question on R memory management in .Fortran() calls under Windows

2005-09-12 Thread Simone Giannerini
Dear Duncan and Simon, many thanks for your helpful reply. Duncan Murdoch wrote: It looks as though your Fortran compiler is allocating the new matrix on the stack. R doesn't give you a huge stack, and that's causing the overflow. When you get R to do the allocation, it does it on the

Re: [Rd] A question on R memory management in .Fortran() calls under Windows

2005-09-12 Thread Duncan Murdoch
Simone Giannerini wrote: Dear Duncan and Simon, many thanks for your helpful reply. Duncan Murdoch wrote: It looks as though your Fortran compiler is allocating the new matrix on the stack. R doesn't give you a huge stack, and that's causing the overflow. When you get R to do the

Re: [Rd] A question on R memory management in .Fortran() calls under Windows

2005-09-12 Thread Simon Urbanek
Simone, On Sep 12, 2005, at 4:30 AM, Simone Giannerini wrote: yes, CVF allocates automatic objects on the stack and apparently there is no way of changing it. Yes, that's bad news. By the way, increasing the stack of the fortran process when linking does not solve the problem In

Re: [Rd] A question on R memory management in .Fortran() calls under Windows

2005-09-12 Thread Simone Giannerini
I think it's far from the best optimizing compiler, but the Fortran that comes with MinGW (g77 currently in Windows) is the one used to build R, so it's the one that will is most likely to work with it without fiddling. But I don't use Fortran, so I don't know what else is available.

[Rd] A question on R memory management in .Fortran() calls under Windows

2005-09-09 Thread Simone Giannerini
Dear R community, I have a question on how R manages memory allocation in .Fortran() calls under Windows. In brief, apparently, it is not possible to allocate large matrices inside a Fortran subroutine unless you pass them as arguments. If you do not act in this way RGUI crashes with a stack

Re: [Rd] A question on R memory management in .Fortran() calls under Windows

2005-09-09 Thread Simon Urbanek
Simone, On Sep 9, 2005, at 1:04 PM, Simone Giannerini wrote: Dear R community, I have a question on how R manages memory allocation in .Fortran() calls under Windows. In brief, apparently, it is not possible to allocate large matrices inside a Fortran subroutine I suspect that this is