-------------------------------------------------------------------------- */
-extern StgPtr allocate ( nat n );
-extern StgPtr allocateInGen ( generation *g, nat n );
-extern StgPtr allocateLocal ( Capability *cap, nat n );
-extern StgPtr allocatePinned ( nat n );
+extern StgPtr allocate ( lnat n );
+extern StgPtr allocateInGen ( generation *g, lnat n );
+extern StgPtr allocateLocal ( Capability *cap, lnat n );
+extern StgPtr allocatePinned ( lnat n );
extern lnat allocatedBytes ( void );
extern bdescr * RTS_VAR(small_alloc_list);
osGetMBlocks(nat n)
{
caddr_t ret;
- lnat size = MBLOCK_SIZE * n;
+ lnat size = MBLOCK_SIZE * (lnat)n;
if (next_request == 0) {
// use gen_map_mblocks the first time.
-------------------------------------------------------------------------- */
StgPtr
-allocateInGen (generation *g, nat n)
+allocateInGen (generation *g, lnat n)
{
step *stp;
bdescr *bd;
if (n >= LARGE_OBJECT_THRESHOLD/sizeof(W_))
{
- nat req_blocks = (lnat)BLOCK_ROUND_UP(n*sizeof(W_)) / BLOCK_SIZE;
+ lnat req_blocks = (lnat)BLOCK_ROUND_UP(n*sizeof(W_)) / BLOCK_SIZE;
// Attempting to allocate an object larger than maxHeapSize
// should definitely be disallowed. (bug #1791)
}
StgPtr
-allocate (nat n)
+allocate (lnat n)
{
return allocateInGen(g0,n);
}
-------------------------------------------------------------------------- */
StgPtr
-allocateLocal (Capability *cap, nat n)
+allocateLocal (Capability *cap, lnat n)
{
bdescr *bd;
StgPtr p;
------------------------------------------------------------------------- */
StgPtr
-allocatePinned( nat n )
+allocatePinned( lnat n )
{
StgPtr p;
bdescr *bd = pinned_object_block;