diff options
author | Mike Pall <mike> | 2009-12-08 20:35:29 +0100 |
---|---|---|
committer | Mike Pall <mike> | 2009-12-08 20:35:29 +0100 |
commit | 3f1f9e11f4f699ae94182d4cba158092f434a7f6 (patch) | |
tree | 88fbb674a21a1d554d4b1ee9d4ef2c5fed6a1d88 /src/lj_alloc.c | |
parent | 5287b9326479ea2b7dddd6f642673e58e5a7f354 (diff) | |
download | luajit-3f1f9e11f4f699ae94182d4cba158092f434a7f6.tar.gz luajit-3f1f9e11f4f699ae94182d4cba158092f434a7f6.tar.bz2 luajit-3f1f9e11f4f699ae94182d4cba158092f434a7f6.zip |
Fast forward to sync public repo.
Compile math.sinh(), math.cosh(), math.tanh() and math.random().
Compile various io.*() functions.
Drive the GC forward on string allocations in the parser.
Improve KNUM fuse vs. load heuristics.
Add abstract C call handling to IR.
Diffstat (limited to 'src/lj_alloc.c')
-rw-r--r-- | src/lj_alloc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lj_alloc.c b/src/lj_alloc.c index 8ad4f8fb..6d8b4ccb 100644 --- a/src/lj_alloc.c +++ b/src/lj_alloc.c | |||
@@ -1186,10 +1186,10 @@ static LJ_NOINLINE void *lj_alloc_realloc(void *msp, void *ptr, size_t nsize) | |||
1186 | size_t rsize = oldsize - nb; | 1186 | size_t rsize = oldsize - nb; |
1187 | newp = oldp; | 1187 | newp = oldp; |
1188 | if (rsize >= MIN_CHUNK_SIZE) { | 1188 | if (rsize >= MIN_CHUNK_SIZE) { |
1189 | mchunkptr remainder = chunk_plus_offset(newp, nb); | 1189 | mchunkptr rem = chunk_plus_offset(newp, nb); |
1190 | set_inuse(m, newp, nb); | 1190 | set_inuse(m, newp, nb); |
1191 | set_inuse(m, remainder, rsize); | 1191 | set_inuse(m, rem, rsize); |
1192 | lj_alloc_free(m, chunk2mem(remainder)); | 1192 | lj_alloc_free(m, chunk2mem(rem)); |
1193 | } | 1193 | } |
1194 | } else if (next == m->top && oldsize + m->topsize > nb) { | 1194 | } else if (next == m->top && oldsize + m->topsize > nb) { |
1195 | /* Expand into top */ | 1195 | /* Expand into top */ |