qccHunkAlloc(): Round block sizes up to the next 8 to make sure all blocks returned are aligned at least to that size. Fixes problems with alignment exceptions occuring on MIPS/Irix and should also improve performance on those systems that silently emulate badly aligned data accesses.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3588 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
a4ed95a376
commit
223ac397af
1 changed files with 2 additions and 0 deletions
|
@ -26,6 +26,8 @@ int qcchunksize;
|
|||
char *qcchunk;
|
||||
void *qccHunkAlloc(size_t mem)
|
||||
{
|
||||
mem = (mem + 7)&~7;
|
||||
|
||||
qccalloced+=mem;
|
||||
if (qccalloced > qcchunksize)
|
||||
QCC_Error(ERR_INTERNAL, "Compile hunk was filled");
|
||||
|
|
Loading…
Reference in a new issue