<commit_before>/*
 * Copyright (c) 2015 <NAME> (<EMAIL>)
 *
 * This is free software: you can redistribute it and/or modify
 * it under the terms of the Artistic License 2.0 as published by
 * The Perl Foundation.
 *
 * This source is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * Artistic License 2.0 for more details.
 *
 * You should have received a copy of the Artistic License 2.0
 * along the source as a COPYING file. If not, obtain it from
 * http://www.perlfoundation.org/artistic_license_2_0.
 */

#if !defined(_WIN32)
# include <sys/mman.h>
#endif
#include <assert.h>
#include <stdlib.h>
#include <string.h>

#include <moony.h>
#include <api_vm.h>

#include <lualib.h>
#include <lauxlib.h>

#define MEM_SIZE 0x20000UL // 128KB

// rt
static inline void *
rt_alloc(moony_vm_t *vm, size_t len)
{
	return tlsf_malloc(vm->tlsf, len);
}

// rt
static inline void *
rt_realloc(moony_vm_t *vm, size_t len, void *buf)<commit_msg>increase minimal rt-memory pool to 256KB.<commit_after>/*
 * Copyright (c) 2015 <NAME> (<EMAIL>)
 *
 * This is free software: you can redistribute it and/or modify
 * it under the terms of the Artistic License 2.0 as published by
 * The Perl Foundation.
 *
 * This source is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * Artistic License 2.0 for more details.
 *
 * You should have received a copy of the Artistic License 2.0
 * along the source as a COPYING file. If not, obtain it from
 * http://www.perlfoundation.org/artistic_license_2_0.
 */

#if !defined(_WIN32)
# include <sys/mman.h>
#endif
#include <assert.h>
#include <stdlib.h>
#include <string.h>

#include <moony.h>
#include <api_vm.h>

#include <lualib.h>
#include <lauxlib.h>

#define MEM_SIZE 0x40000UL // 256KB

// rt
static inline void *
rt_alloc(moony_vm_t *vm, size_t len)
{
	return tlsf_malloc(vm->tlsf, len);
}

// rt
static inline void *
rt_realloc(moony_vm_t *vm, size_t len, void *buf)
{'fraction_non_alphanumeric': 0.10545790934320073, 'fraction_numerical': 0.022664199814986123, 'mean_word_length': 4.006944444444445, 'pattern_counts': {'":': 0, '<': 23, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5943481', 'n_tokens_mistral': 777, 'n_tokens_neox': 728, 'n_words': 276}