cb_malloc(3B)                                           Last changed: 06-29-03

NAME
	cb_malloc - allocate block aligned memory region.

SYNOPSIS

	C/C++:

	#include <cbl.h>
	void *cb_malloc(long nbytes);

IMPLEMENTATION

	UNICOS/mp and Cray SV1 series UNICOS systems

DESCRIPTION

	cb_malloc allocates memory using the Fortran allocate statement. On
	the SV1 this memory is aligned on 512 word address boundaries if the
	amount of memory requested is large. cb_malloc can be used to 
	allocate memory appropriate for the cb_ssd_* routines. Memory allocated
	using cb_malloc must be deallocated using cb_free(), and not free().
	cb_malloc returns a void pointer that should be cast to the appropriate
	data type, just as with malloc().

	nbytes	input number of bytes of memory to be allocated.

NOTES       
	cb_malloc is single-threaded (i.e. not tasked) but contains updates of
	internal data structures that are not thread safe. If cb_malloc is called
	from within a parallel region it should be done from within a protected
	region.

	cb_malloc is intended for C programmers only. In a Fortran program, arrays
	aligned arrays can be allocated using the allocate statement.

SEE ALSO

	cb_free(3B), INTRO_LIBCBL(3B)

	This man page is available only online.

Index of man pages