AFAIK, the 4GB limit on (teraspace) allocations addressable by a 16-byte
pointer is an artifact of the 4-byte unsigned size_t parameter to malloc().

(To get anything over 16MB in a single allocation you must be using
teraspace -- single-level store segments are 16MB in size.)

Now, for fun numbers:

The theoretical limit for 16-byte pointers is ( 2^128 - 1 ) or
340,282,366,920,938,463,463,374,607,431,768,211,455 bytes.

The theoretical limit for 8-byte pointers (used by the PowerN hardware) is
( 2^64 - 1 ) or 18,446,744,073,709,551,615 bytes.

The theoretical limit for teraspace addresses is 2^40-1 or
1,099,511,627,775 bytes (1 terabyte -- hence the name).



  ___   _           Blair Wyman                  IBM Rochester
 ( /_)  /  _  ' _   (507)253-2891            blairw@xxxxxxxxxx
__/__)_/_<_/_/_/_'  Opinions expressed may not be those of IBM

             "Keith Carpenter"                                             
             Sent by:                                                   To 
             c400-l-bounces@mi         "C programming iSeries / AS400"     
             07/01/2004 06:12                                      Subject 
             PM                        Re: [C400-L] RE: Porting C Linux to 
                                       ILE C: Performance problem          
             Please respond to                                             
               C programming                                               
              iSeries / AS400                                              

4gb is the limit for 16 byte pointers.
Larger allocations require 8 byte pointers and DTAMDL(*LLP64)

Apparently these 8 byte pointers should also perform better.
ILE concepts, Chapter 4.

> It sounds to me though, that the original poster really needs to look at
> teraspace compile options.  With it, you can allocate up to 4GB blocks
> V5R1).

This is the C programming iSeries / AS400 (C400-L) mailing list
To post a message email: C400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
or email: C400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2019 by and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].