[MPlayer-dev-eng] memalign on win32
Gianluigi Tiesi
mplayer at netfarm.it
Fri May 20 19:57:33 CEST 2005
I was studying about memalign and win32, I've found the mingw32
implementation:
http://cvs.sourceforge.net/viewcvs.py/mingw/runtime/mingwex/mingw-aligned-malloc.c?rev=1.1&sortby=date&view=auto
is in mingwex lib, however it seams very close to the memalign hack,
but looking at mingw malloc.h include:
/* These require msvcr70.dll or higher. */
#if __MSVCRT_VERSION__ >= 0x0700
_CRTIMP void * __cdecl _aligned_offset_malloc(size_t, size_t, size_t);
_CRTIMP void * __cdecl _aligned_offset_realloc(void*, size_t, size_t,
size_t);
_CRTIMP void * __cdecl _aligned_malloc (size_t, size_t);
_CRTIMP void * __cdecl _aligned_realloc (void*, size_t, size_t);
_CRTIMP void __cdecl _aligned_free (void*);
#endif /* __MSVCRT_VERSION__ >= 0x0700 */
So I've found on m$ site:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclib/html/vclrfdataalignment.asp
So msvcrt70 dll has an implementation of memalign, it should be
considered better than the memalign hack?
--
Gianluigi Tiesi <sherpya at netfarm.it>
EDP Project Leader
Netfarm S.r.l. - http://www.netfarm.it/
Free Software: http://oss.netfarm.it/
More information about the MPlayer-dev-eng
mailing list