On Nov 13, 2008, at 9:11 PM, Rich Siegel wrote:

>
> On 11/13/08 at 9:30 PM, [EMAIL PROTECTED] (David Kelly) wrote:
>
>> Thats what I said. To the effect the table allocation for
>> tracking  resources was statically allocated and therefore limited.
>
> That actually has nothing to do with it. :-) Other allocations,
> e.g. via malloc() do not share the same limitation. It's an
> implementation detail of NewHandle() in the guts of the OS, and
> is for us to work around at some future point.

Very interesting. malloc() does work for 2 GB. Broke at 3 GB:

#include <stdlib.h>
#include <stdio.h>
#include <stdint.h>
#include <unistd.h>

#define GIGABYTES        2000000000UL

main()
{
         uint32_t        i;
         char *cp;

         cp = malloc( GIGABYTES );
         printf("cp = 0x%08x\n", cp );

         for( i = 0 ; i < GIGABYTES ; i++ )
                 cp[i] = 0x55;

         printf("sleeping\n");
         sleep( 1000 );

}

--
David Kelly N4HHE, [EMAIL PROTECTED]
========================================================================
Whom computers would destroy, they must first drive mad.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "BBEdit Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/bbedit?hl=en
If you have a specific feature request or would like to report a suspected (or 
confirmed) problem with the software, please email to "[EMAIL PROTECTED]" 
rather than posting to the group.
-~----------~----~----~----~------~----~------~--~---

Reply via email to