Mail Archives: cygwin/2006/03/30/06:08:22
On Mar 30 11:29, Dave Korn wrote:
> On 29 March 2006 21:22, Pete wrote:
>
> > I have some benchmarkign code
> >
> > #define N 600 // Matrix rank
> > #define ITERATIONS 2000
> >
> >
> >
> > int main( void )
> > {
> > // Set up the timer and start it ticking.
> > Timer timer;
> > timer.startTimer();
> >
> > // We multiply m1 and m2, and put the result in m3.
> > int m1[N][N];
> > int m2[N][N];
> > int m3[N][N];
> > ...
> >
>
> Your testcase didn't even compile for me! It complained about those three
> dots!
>
> > On Cygwin, the code runs fine for a matrix rank
> > between 400 and 0. Somewhere N=400 and N=600, the
> > program segfaults under Cygwin.
No wonder. 600**3 * sizeof (int) * 3 == 2592000000 ~= 2.4 Gigs.
Somehow I doubt that this works at all. Each Windows process has
only up to 2 Gigs of memory, except the Windows kernel has been started
with the /3G option.
In these 2 Gigs, you also have to have room for the DLLs. Assuming the
Cygwin DLL is the lowest DLL in memory at 0x61000000, and assuming the
application is loaded at 0x400000, as usual, you have typically left
0x61000000 - 0x400000 == 0x60c00000 == 1623195648 ~= 1.5Gigs left for
the application.
Corinna
--
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Project Co-Leader cygwin AT cygwin DOT com
Red Hat
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
- Raw text -