Skip site navigation (1) Skip section navigation (2)

Re: [GENERAL] memory

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Daniel Kalchev <daniel(at)digsys(dot)bg>
Cc: PostgreSQL-ports <pgsql-ports(at)postgreSQL(dot)org>
Subject: Re: [GENERAL] memory
Date: 1999-12-07 03:21:09
Message-ID: 199912070321.WAA19688@candle.pha.pa.us (view raw or flat)
Thread:
Lists: pgsql-ports
> Bruce,
> 
> As suggested, I wrote the following program (test.c):
> 
> --- cut here ---
> #include <stdlib.h>
> 
> main()
> {
>     int allocated = 0;
>     int mb = 1024 * 1024;
> 
>     while (malloc(mb) != NULL) {
>         allocated ++;
>         printf ("%d MB allocated\n", allocated);
>     }
> }

OK, we use malloc for memory allocation, and the error you were getting
was from that function that does that, I think.  I am confused.  Could
it be stack space somehow?

-- 
  Bruce Momjian                        |  http://www.op.net/~candle
  maillist(at)candle(dot)pha(dot)pa(dot)us            |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

In response to

pgsql-ports by date

Next:From: Clemens VonrheinDate: 1999-12-08 12:23:56
Subject: port to IRIX 6.3
Previous:From: adamDate: 1999-12-07 01:39:05
Subject: Travel Companies Reach the World

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group