Use realloc for ByteCodeGeneration

Signed-off-by: Seonghyun Kim <sh8281.kim@samsung.com>
This commit is contained in:
Seonghyun Kim 2023-12-22 14:15:57 +09:00 committed by Patrick Kim
commit b0543cfe9c
7 changed files with 220 additions and 30 deletions

View file

@ -395,9 +395,9 @@ void CodeCacheWriter::storeByteCodeStream(ByteCodeBlock* block)
// mark bytecode relocation infos
{
char* code = byteCodeStream.data();
uint8_t* code = byteCodeStream.data();
size_t codeBase = (size_t)code;
char* end = code + byteCodeStream.size();
uint8_t* end = code + byteCodeStream.size();
Context* context = block->codeBlock()->context();
@ -985,8 +985,8 @@ void CodeCacheReader::loadByteCodeStream(Context* context, ByteCodeBlock* block)
// relocate ByteCodeStream
{
char* code = byteCodeStream.data();
char* end = code + byteCodeStream.size();
uint8_t* code = byteCodeStream.data();
uint8_t* end = code + byteCodeStream.size();
InterpretedCodeBlock* codeBlock = block->codeBlock();