• Home
  • Raw
  • Download

Lines Matching refs:memory

254     *memory;  in AcquireAlignedMemory()  local
258 memory=NULL; in AcquireAlignedMemory()
265 if (posix_memalign(&memory,alignment,extent) != 0) in AcquireAlignedMemory()
266 memory=NULL; in AcquireAlignedMemory()
268 memory=_aligned_malloc(extent,alignment); in AcquireAlignedMemory()
291 memory=(void *) AlignedExtent((size_t) p+sizeof(void *),alignment); in AcquireAlignedMemory()
292 *((void **) memory-1)=p; in AcquireAlignedMemory()
297 return(memory); in AcquireAlignedMemory()
475 *memory; in AcquireMagickMemory() local
478 memory=memory_methods.acquire_memory_handler(size == 0 ? 1UL : size); in AcquireMagickMemory()
507 memory=AcquireBlock(size == 0 ? 1UL : size); in AcquireMagickMemory()
508 if (memory == (void *) NULL) in AcquireMagickMemory()
511 memory=AcquireBlock(size == 0 ? 1UL : size); in AcquireMagickMemory()
515 return(memory); in AcquireMagickMemory()
1032 MagickExport void *RelinquishAlignedMemory(void *memory) in RelinquishAlignedMemory() argument
1034 if (memory == (void *) NULL) in RelinquishAlignedMemory()
1037 free(memory); in RelinquishAlignedMemory()
1039 _aligned_free(memory); in RelinquishAlignedMemory()
1041 free(*((void **) memory-1)); in RelinquishAlignedMemory()
1069 MagickExport void *RelinquishMagickMemory(void *memory) in RelinquishMagickMemory() argument
1071 if (memory == (void *) NULL) in RelinquishMagickMemory()
1074 memory_methods.destroy_memory_handler(memory); in RelinquishMagickMemory()
1077 assert((SizeOfBlock(memory) % (4*sizeof(size_t))) == 0); in RelinquishMagickMemory()
1078 assert((*BlockHeader(NextBlock(memory)) & PreviousBlockBit) != 0); in RelinquishMagickMemory()
1079 if ((*BlockHeader(memory) & PreviousBlockBit) == 0) in RelinquishMagickMemory()
1087 previous=PreviousBlock(memory); in RelinquishMagickMemory()
1089 *BlockHeader(previous)=(SizeOfBlock(previous)+SizeOfBlock(memory)) | in RelinquishMagickMemory()
1091 memory=previous; in RelinquishMagickMemory()
1093 if ((*BlockHeader(NextBlock(NextBlock(memory))) & PreviousBlockBit) == 0) in RelinquishMagickMemory()
1101 next=NextBlock(memory); in RelinquishMagickMemory()
1103 *BlockHeader(memory)=(SizeOfBlock(memory)+SizeOfBlock(next)) | in RelinquishMagickMemory()
1104 (*BlockHeader(memory) & ~SizeMask); in RelinquishMagickMemory()
1106 *BlockFooter(memory,SizeOfBlock(memory))=SizeOfBlock(memory); in RelinquishMagickMemory()
1107 *BlockHeader(NextBlock(memory))&=(~PreviousBlockBit); in RelinquishMagickMemory()
1108 InsertFreeBlock(memory,AllocationPolicy(SizeOfBlock(memory))); in RelinquishMagickMemory()
1195 MagickExport void *ResetMagickMemory(void *memory,int byte,const size_t size) in ResetMagickMemory() argument
1197 assert(memory != (void *) NULL); in ResetMagickMemory()
1198 return(memset(memory,byte,size)); in ResetMagickMemory()
1278 *memory; in ResizeBlock() local
1282 memory=AcquireBlock(size); in ResizeBlock()
1283 if (memory == (void *) NULL) in ResizeBlock()
1286 (void) memcpy(memory,block,size); in ResizeBlock()
1288 (void) memcpy(memory,block,SizeOfBlock(block)-sizeof(size_t)); in ResizeBlock()
1290 return(memory); in ResizeBlock()
1294 MagickExport void *ResizeMagickMemory(void *memory,const size_t size) in ResizeMagickMemory() argument
1299 if (memory == (void *) NULL) in ResizeMagickMemory()
1302 block=memory_methods.resize_memory_handler(memory,size == 0 ? 1UL : size); in ResizeMagickMemory()
1304 memory=RelinquishMagickMemory(memory); in ResizeMagickMemory()
1307 block=ResizeBlock(memory,size == 0 ? 1UL : size); in ResizeMagickMemory()
1313 memory=RelinquishMagickMemory(memory); in ResizeMagickMemory()
1316 block=ResizeBlock(memory,size == 0 ? 1UL : size); in ResizeMagickMemory()
1320 memory=RelinquishMagickMemory(memory); in ResizeMagickMemory()
1354 MagickExport void *ResizeQuantumMemory(void *memory,const size_t count, in ResizeQuantumMemory() argument
1362 memory=RelinquishMagickMemory(memory); in ResizeQuantumMemory()
1366 return(ResizeMagickMemory(memory,extent)); in ResizeQuantumMemory()