#include "linden_common.h"
#include "lscript_alloc.h"
#include "llrand.h"
Include dependency graph for lscript_library/lscript_alloc.cpp:
Go to the source code of this file.
Definition at line 919 of file lscript_library/lscript_alloc.cpp.
References get_register(), LREG_FR, lsa_get_data(), lsa_heap_add_data(), LSRF_HEAP_ERROR, LST_LIST, LLScriptLibData::mListp, LLScriptLibData::mType, NULL, tut::runner, set_fault(), and TRUE.
Referenced by list_list_operation().
Definition at line 660 of file lscript_library/lscript_alloc.cpp.
References get_register(), LREG_FR, lsa_get_data(), lsa_heap_add_data(), LSRF_HEAP_ERROR, LST_KEY, LST_STRING, LLScriptLibData::mKey, LLScriptLibData::mString, LLScriptLibData::mType, NULL, S32, set_fault(), size, and TRUE.
Referenced by string_string_operation().
Definition at line 971 of file lscript_library/lscript_alloc.cpp.
References FALSE, get_register(), LLScriptLibData::getListLength(), LREG_FR, lsa_get_data(), LSRF_HEAP_ERROR, LST_LIST, LLScriptLibData::mType, S32, set_fault(), and TRUE.
Referenced by list_list_operation().
Definition at line 728 of file lscript_library/lscript_alloc.cpp.
References get_register(), LREG_FR, lsa_get_data(), LSRF_HEAP_ERROR, LST_KEY, LST_STRING, LLScriptLibData::mKey, LLScriptLibData::mString, LLScriptLibData::mType, NULL, S32, set_fault(), and TRUE.
Referenced by key_key_operation(), key_string_operation(), string_key_operation(), and string_string_operation().
S32 lsa_create_data_block | ( | U8 ** | buffer, | |
LLScriptLibData * | data, | |||
S32 | base_offset | |||
) |
Definition at line 327 of file lscript_library/lscript_alloc.cpp.
References alloc_entry2bytestream(), byte2bytestream(), char2bytestream(), float2bytestream(), LLScriptLibData::getListLength(), integer2bytestream(), llendl, llerrs, lsa_create_data_block(), LSCRIPTDataSize, LST_FLOATINGPOINT, LST_INTEGER, LST_KEY, LST_LIST, LST_NULL, LST_QUATERNION, LST_STRING, LST_VECTOR, MAX_HEAP_SIZE, LLScriptLibData::mFP, LLScriptLibData::mInteger, LLScriptLibData::mKey, LLScriptLibData::mListp, LLScriptLibData::mQuat, LLScriptAllocEntry::mReferenceCount, LLScriptAllocEntry::mSize, LLScriptLibData::mString, LLScriptLibData::mType, LLScriptAllocEntry::mType, LLScriptLibData::mVec, NULL, quaternion2bytestream(), S32, size, SIZEOF_SCRIPT_ALLOC_ENTRY, and vector2bytestream().
Referenced by lsa_create_data_block(), LLScriptConstantString::recurse(), LLScriptSAList::recurse(), LLScriptGlobalVariable::recurse(), and LLScriptScript::recurse().
Definition at line 69 of file lscript_library/lscript_alloc.cpp.
References alloc_entry2bytestream(), LST_NULL, S32, and TRUE.
Definition at line 486 of file lscript_library/lscript_alloc.cpp.
References alloc_entry2bytestream(), bytestream2alloc_entry(), bytestream2integer(), get_register(), i, LREG_FR, LREG_HP, LREG_HR, lsa_decrease_ref_count(), LSRF_BOUND_CHECK_ERROR, LSRF_HEAP_ERROR, LST_LIST, LST_NULL, LLScriptAllocEntry::mReferenceCount, LLScriptAllocEntry::mType, S32, and set_fault().
Referenced by lsa_decrease_ref_count(), lsa_get_data(), lsa_get_list_ptr(), lscript_pop_variable(), lscript_stacktol_pop_variable(), run_cast(), run_jumpif(), run_jumpnif(), run_loadglp(), run_loadgsp(), run_loadlp(), run_loadsp(), run_popl(), run_pops(), run_print(), run_storegl(), run_storegs(), run_storel(), and run_stores().
Definition at line 852 of file lscript_library/lscript_alloc.cpp.
References bytestream2alloc_entry(), bytestream2char(), bytestream2float(), bytestream2integer(), bytestream2quaternion(), bytestream2vector(), get_register(), LREG_HR, LSCRIPTTypeNames, LST_FLOATINGPOINT, LST_INTEGER, LST_KEY, LST_LIST, LST_QUATERNION, LST_STRING, LST_VECTOR, MAX_HEAP_SIZE, LLQuaternion::mQ, LLScriptAllocEntry::mReferenceCount, LLScriptAllocEntry::mSize, LLScriptAllocEntry::mType, LLVector3::mV, S32, VS, VX, VY, and VZ.
Referenced by LLScriptLSOParse::printHeap().
LLScriptLibData* lsa_get_data | ( | U8 * | buffer, | |
S32 & | offset, | |||
BOOL | b_dec_ref | |||
) |
Definition at line 530 of file lscript_library/lscript_alloc.cpp.
References bytestream2alloc_entry(), bytestream2char(), bytestream2float(), bytestream2integer(), bytestream2quaternion(), bytestream2vector(), LLScriptLibData::checkForMultipleLists(), FALSE, get_register(), gLSAStringRead, i, LREG_FR, LREG_HP, LREG_HR, lsa_decrease_ref_count(), lsa_get_data(), LSRF_BOUND_CHECK_ERROR, LSRF_HEAP_ERROR, LSRF_NESTING_LISTS, LST_FLOATINGPOINT, LST_INTEGER, LST_KEY, LST_LIST, LST_QUATERNION, LST_STRING, LST_VECTOR, LLScriptLibData::mFP, LLScriptLibData::mInteger, LLScriptLibData::mKey, LLScriptLibData::mListp, LLScriptLibData::mQuat, LLScriptLibData::mString, LLScriptLibData::mType, LLScriptAllocEntry::mType, LLScriptLibData::mVec, S32, and set_fault().
Referenced by key_list_operation(), list_key_operation(), list_string_operation(), lsa_cat_lists(), lsa_cat_strings(), lsa_cmp_lists(), lsa_cmp_strings(), lsa_get_data(), lsa_get_list_ptr(), lsa_postadd_lists(), lsa_preadd_lists(), lscript_stacktol_pop_variable(), run_cast(), run_print(), and string_list_operation().
LLScriptLibData* lsa_get_list_ptr | ( | U8 * | buffer, | |
S32 & | offset, | |||
BOOL | b_dec_ref | |||
) |
Definition at line 610 of file lscript_library/lscript_alloc.cpp.
References base, bytestream2alloc_entry(), bytestream2integer(), FALSE, get_register(), i, LREG_FR, LREG_HP, LREG_HR, lsa_decrease_ref_count(), lsa_get_data(), LSRF_BOUND_CHECK_ERROR, LSRF_HEAP_ERROR, LST_LIST, LLScriptLibData::mListp, LLScriptAllocEntry::mType, NULL, S32, and set_fault().
Referenced by lscript_pop_variable(), run_jumpif(), and run_jumpnif().
S32 lsa_heap_add_data | ( | U8 * | buffer, | |
LLScriptLibData * | data, | |||
S32 | heapsize, | |||
BOOL | b_delete | |||
) |
Definition at line 115 of file lscript_library/lscript_alloc.cpp.
References alloc_entry2bytestream(), bytestream2alloc_entry(), LLScriptLibData::checkForMultipleLists(), get_register(), LLScriptLibData::getListLength(), LREG_FR, LREG_HP, LREG_HR, lsa_insert_data(), lsa_split_block(), LSRF_NESTING_LISTS, LSRF_STACK_HEAP_COLLISION, LST_FLOATINGPOINT, LST_INTEGER, LST_KEY, LST_LIST, LST_QUATERNION, LST_STRING, LST_VECTOR, LLScriptLibData::mKey, LLScriptAllocEntry::mReferenceCount, LLScriptAllocEntry::mSize, LLScriptLibData::mString, LLScriptAllocEntry::mType, LLScriptLibData::mType, reset_hp_to_safe_spot(), S32, set_fault(), set_register(), size, and SIZEOF_SCRIPT_ALLOC_ENTRY.
Referenced by lsa_cat_lists(), lsa_cat_strings(), lsa_insert_data(), lsa_postadd_lists(), lsa_preadd_lists(), lscript_push_return_variable(), lscript_push_variable(), run_cast(), run_pushargs(), run_stacktol(), and run_stacktos().
Definition at line 80 of file lscript_library/lscript_alloc.cpp.
References bytestream2alloc_entry(), LLScriptAllocEntry::mSize, and S32.
Definition at line 459 of file lscript_library/lscript_alloc.cpp.
References alloc_entry2bytestream(), bytestream2alloc_entry(), get_register(), LREG_FR, LREG_HP, LREG_HR, LSRF_BOUND_CHECK_ERROR, LLScriptAllocEntry::mReferenceCount, S32, and set_fault().
Referenced by run_dupl(), run_dups(), run_pushgl(), run_pushgs(), run_pushl(), run_pushs(), run_storegl(), run_storegs(), run_storel(), and run_stores().
void lsa_insert_data | ( | U8 * | buffer, | |
S32 & | offset, | |||
LLScriptLibData * | data, | |||
LLScriptAllocEntry & | entry, | |||
S32 | heapsize | |||
) |
Definition at line 282 of file lscript_library/lscript_alloc.cpp.
References char2bytestream(), FALSE, float2bytestream(), get_register(), LLScriptLibData::getListLength(), integer2bytestream(), LREG_FR, lsa_heap_add_data(), LST_FLOATINGPOINT, LST_INTEGER, LST_KEY, LST_LIST, LST_QUATERNION, LST_STRING, LST_VECTOR, LLScriptLibData::mFP, LLScriptLibData::mInteger, LLScriptLibData::mKey, LLScriptLibData::mListp, LLScriptLibData::mQuat, LLScriptLibData::mString, LLScriptLibData::mType, LLScriptLibData::mVec, quaternion2bytestream(), S32, and vector2bytestream().
Referenced by lsa_heap_add_data().
S32 lsa_postadd_lists | ( | U8 * | buffer, | |
S32 | offset1, | |||
LLScriptLibData * | data, | |||
S32 | heapsize | |||
) |
Definition at line 1049 of file lscript_library/lscript_alloc.cpp.
References get_register(), LREG_FR, lsa_get_data(), lsa_heap_add_data(), LSRF_HEAP_ERROR, LST_LIST, LLScriptLibData::mListp, LLScriptLibData::mType, tut::runner, set_fault(), and TRUE.
Referenced by list_float_operation(), list_integer_operation(), list_key_operation(), list_quaternion_operation(), list_string_operation(), and list_vector_operation().
S32 lsa_preadd_lists | ( | U8 * | buffer, | |
LLScriptLibData * | data, | |||
S32 | offset2, | |||
S32 | heapsize | |||
) |
Definition at line 1014 of file lscript_library/lscript_alloc.cpp.
References get_register(), LREG_FR, lsa_get_data(), lsa_heap_add_data(), LSRF_HEAP_ERROR, LST_LIST, LLScriptLibData::mListp, LLScriptLibData::mType, tut::runner, set_fault(), and TRUE.
Referenced by float_list_operation(), integer_list_operation(), key_list_operation(), quaternion_list_operation(), string_list_operation(), and vector_list_operation().
Definition at line 782 of file lscript_library/lscript_alloc.cpp.
References bytestream2alloc_entry(), bytestream2char(), bytestream2float(), bytestream2integer(), bytestream2quaternion(), bytestream2vector(), get_register(), LREG_HP, LREG_HR, LSCRIPTTypeNames, LST_FLOATINGPOINT, LST_INTEGER, LST_KEY, LST_LIST, LST_QUATERNION, LST_STRING, LST_VECTOR, MAX_HEAP_SIZE, LLQuaternion::mQ, LLScriptAllocEntry::mReferenceCount, LLScriptAllocEntry::mSize, LLScriptAllocEntry::mType, LLVector3::mV, S32, VS, VX, VY, and VZ.
LLScriptLibData* lsa_randomize | ( | LLScriptLibData * | src, | |
S32 | stride | |||
) |
Definition at line 1082 of file lscript_library/lscript_alloc.cpp.
References LLScriptLibData::getListLength(), ll_rand(), LLScriptLibData::mListp, NULL, and S32.
void lsa_split_block | ( | U8 * | buffer, | |
S32 & | offset, | |||
S32 | size, | |||
LLScriptAllocEntry & | entry | |||
) |
Definition at line 258 of file lscript_library/lscript_alloc.cpp.
References alloc_entry2bytestream(), get_register(), LREG_FR, LLScriptAllocEntry::mSize, S32, and SIZEOF_SCRIPT_ALLOC_ENTRY.
Referenced by lsa_heap_add_data().
Definition at line 63 of file lscript_library/lscript_alloc.cpp.
References LREG_HP, set_register(), and TOP_OF_MEMORY.
char gLSAStringRead[16384] |