|
xine-lib
1.2.10
|
#include <math.h>#include <stdlib.h>#include <stdio.h>#include <string.h>#include "goomsl.h"#include "goomsl_private.h"#include "goomsl_yacc.h"Macros | |
| #define | INSTR_SETI_VAR_INTEGER 1 |
| #define | INSTR_SETI_VAR_VAR 2 |
| #define | INSTR_SETF_VAR_FLOAT 3 |
| #define | INSTR_SETF_VAR_VAR 4 |
| #define | INSTR_NOP 5 |
| #define | INSTR_SETP_VAR_PTR 7 |
| #define | INSTR_SETP_VAR_VAR 8 |
| #define | INSTR_SUBI_VAR_INTEGER 9 |
| #define | INSTR_SUBI_VAR_VAR 10 |
| #define | INSTR_SUBF_VAR_FLOAT 11 |
| #define | INSTR_SUBF_VAR_VAR 12 |
| #define | INSTR_ISLOWERF_VAR_VAR 13 |
| #define | INSTR_ISLOWERF_VAR_FLOAT 14 |
| #define | INSTR_ISLOWERI_VAR_VAR 15 |
| #define | INSTR_ISLOWERI_VAR_INTEGER 16 |
| #define | INSTR_ADDI_VAR_INTEGER 17 |
| #define | INSTR_ADDI_VAR_VAR 18 |
| #define | INSTR_ADDF_VAR_FLOAT 19 |
| #define | INSTR_ADDF_VAR_VAR 20 |
| #define | INSTR_MULI_VAR_INTEGER 21 |
| #define | INSTR_MULI_VAR_VAR 22 |
| #define | INSTR_MULF_VAR_FLOAT 23 |
| #define | INSTR_MULF_VAR_VAR 24 |
| #define | INSTR_DIVI_VAR_INTEGER 25 |
| #define | INSTR_DIVI_VAR_VAR 26 |
| #define | INSTR_DIVF_VAR_FLOAT 27 |
| #define | INSTR_DIVF_VAR_VAR 28 |
| #define | INSTR_ISEQUALP_VAR_VAR 30 |
| #define | INSTR_ISEQUALP_VAR_PTR 31 |
| #define | INSTR_ISEQUALI_VAR_VAR 32 |
| #define | INSTR_ISEQUALI_VAR_INTEGER 33 |
| #define | INSTR_ISEQUALF_VAR_VAR 34 |
| #define | INSTR_ISEQUALF_VAR_FLOAT 35 |
| #define | INSTR_NOT_VAR 39 |
| #define | INSTR_SETS_VAR_VAR 41 |
| #define | INSTR_ISEQUALS_VAR_VAR 42 |
| #define | INSTR_ADDS_VAR_VAR 43 |
| #define | INSTR_SUBS_VAR_VAR 44 |
| #define | INSTR_MULS_VAR_VAR 45 |
| #define | INSTR_DIVS_VAR_VAR 46 |
| #define | VALIDATE_ERROR "error while validating " |
| #define | VALIDATE_TODO "todo" |
| #define | VALIDATE_SYNTHAX_ERROR "synthax error" |
| #define | VALIDATE_NO_SUCH_INT "no such integer variable" |
| #define | VALIDATE_NO_SUCH_VAR "no such variable" |
| #define | VALIDATE_NO_SUCH_DEST_VAR "no such destination variable" |
| #define | VALIDATE_NO_SUCH_SRC_VAR "no such src variable" |
| #define | pSRC_VAR instr[ip].data.usrc.var |
| #define | SRC_VAR_INT *instr[ip].data.usrc.var_int |
| #define | SRC_VAR_FLOAT *instr[ip].data.usrc.var_float |
| #define | SRC_VAR_PTR *instr[ip].data.usrc.var_ptr |
| #define | pDEST_VAR instr[ip].data.udest.var |
| #define | DEST_VAR_INT *instr[ip].data.udest.var_int |
| #define | DEST_VAR_FLOAT *instr[ip].data.udest.var_float |
| #define | DEST_VAR_PTR *instr[ip].data.udest.var_ptr |
| #define | VALUE_INT instr[ip].data.usrc.value_int |
| #define | VALUE_FLOAT instr[ip].data.usrc.value_float |
| #define | VALUE_PTR instr[ip].data.usrc.value_ptr |
| #define | JUMP_OFFSET instr[ip].data.udest.jump_offset |
| #define | SRC_STRUCT_ID instr[ip].data.usrc.var_int[-1] |
| #define | DEST_STRUCT_ID instr[ip].data.udest.var_int[-1] |
| #define | SRC_STRUCT_IBLOCK(i) gsl->gsl_struct[SRC_STRUCT_ID]->iBlock[i] |
| #define | SRC_STRUCT_FBLOCK(i) gsl->gsl_struct[SRC_STRUCT_ID]->fBlock[i] |
| #define | DEST_STRUCT_IBLOCK(i) gsl->gsl_struct[DEST_STRUCT_ID]->iBlock[i] |
| #define | DEST_STRUCT_FBLOCK(i) gsl->gsl_struct[DEST_STRUCT_ID]->fBlock[i] |
| #define | DEST_STRUCT_IBLOCK_VAR(i, j) ((int*)((char*)pDEST_VAR + gsl->gsl_struct[DEST_STRUCT_ID]->iBlock[i].data))[j] |
| #define | DEST_STRUCT_FBLOCK_VAR(i, j) ((float*)((char*)pDEST_VAR + gsl->gsl_struct[DEST_STRUCT_ID]->fBlock[i].data))[j] |
| #define | SRC_STRUCT_IBLOCK_VAR(i, j) ((int*)((char*)pSRC_VAR + gsl->gsl_struct[SRC_STRUCT_ID]->iBlock[i].data))[j] |
| #define | SRC_STRUCT_FBLOCK_VAR(i, j) ((float*)((char*)pSRC_VAR + gsl->gsl_struct[SRC_STRUCT_ID]->fBlock[i].data))[j] |
| #define | DEST_STRUCT_SIZE gsl->gsl_struct[DEST_STRUCT_ID]->size |
Functions | |
| static void | gsl_instr_free (Instruction *_this) |
| static const char * | gsl_instr_validate (Instruction *_this) |
| static void | gsl_instr_display (Instruction *_this) |
| static InstructionFlow * | iflow_new (void) |
| static void | iflow_add_instr (InstructionFlow *_this, Instruction *instr) |
| static void | iflow_clean (InstructionFlow *_this) |
| static void | iflow_free (InstructionFlow *_this) |
| static void | iflow_execute (FastInstructionFlow *_this, GoomSL *gsl) |
| void | gsl_instr_set_namespace (Instruction *_this, GoomHash *ns) |
| void | gsl_instr_add_param (Instruction *instr, const char *param, int type) |
| Instruction * | gsl_instr_init (GoomSL *parent, const char *name, int id, int nb_param, int line_number) |
| static const char * | validate_v_v (Instruction *_this) |
| static const char * | validate_v_i (Instruction *_this) |
| static const char * | validate_v_p (Instruction *_this) |
| static const char * | validate_v_f (Instruction *_this) |
| static const char * | validate (Instruction *_this, int vf_f_id, int vf_v_id, int vi_i_id, int vi_v_id, int vp_p_id, int vp_v_id, int vs_v_id) |
| int | gsl_malloc (GoomSL *_this, int size) |
| void * | gsl_get_ptr (GoomSL *_this, int id) |
| void | gsl_free_ptr (GoomSL *_this, int id) |
| void | gsl_enternamespace (const char *name) |
| void | gsl_reenternamespace (GoomHash *nsinfo) |
| GoomHash * | gsl_leavenamespace (void) |
| GoomHash * | gsl_find_namespace (const char *name) |
| void | gsl_declare_task (const char *name) |
| void | gsl_declare_external_task (const char *name) |
| static void | reset_scanner (GoomSL *gss) |
| static void | calculate_labels (InstructionFlow *iflow) |
| static void | gsl_create_fast_iflow (void) |
| void | yy_scan_string (const char *str) |
| void | yyparse (void) |
| GoomHash * | gsl_globals (GoomSL *_this) |
| static void | ext_charAt (GoomSL *gsl, GoomHash *global, GoomHash *local) |
| static void | ext_i2f (GoomSL *gsl, GoomHash *global, GoomHash *local) |
| static void | ext_f2i (GoomSL *gsl, GoomHash *global, GoomHash *local) |
| void | gsl_compile (GoomSL *_currentGoomSL, const char *script) |
| void | gsl_execute (GoomSL *scanner) |
| GoomSL * | gsl_new (void) |
| void | gsl_bind_function (GoomSL *gss, const char *fname, GoomSL_ExternalFunction func) |
| int | gsl_is_compiled (GoomSL *gss) |
| void | gsl_free (GoomSL *gss) |
| char * | gsl_init_buffer (const char *fname) |
| static char * | gsl_read_file (const char *fname) |
| void | gsl_append_file_to_buffer (const char *fname, char **buffer) |
Variables | |
| static const char * | VALIDATE_OK = "ok" |
| static int | gsl_nb_import |
| static char | gsl_already_imported [256][256] |
| #define DEST_STRUCT_FBLOCK | ( | i | ) | gsl->gsl_struct[DEST_STRUCT_ID]->fBlock[i] |
| #define DEST_STRUCT_FBLOCK_VAR | ( | i, | |
| j | |||
| ) | ((float*)((char*)pDEST_VAR + gsl->gsl_struct[DEST_STRUCT_ID]->fBlock[i].data))[j] |
| #define DEST_STRUCT_IBLOCK | ( | i | ) | gsl->gsl_struct[DEST_STRUCT_ID]->iBlock[i] |
| #define DEST_STRUCT_IBLOCK_VAR | ( | i, | |
| j | |||
| ) | ((int*)((char*)pDEST_VAR + gsl->gsl_struct[DEST_STRUCT_ID]->iBlock[i].data))[j] |
| #define DEST_STRUCT_ID instr[ip].data.udest.var_int[-1] |
| #define DEST_STRUCT_SIZE gsl->gsl_struct[DEST_STRUCT_ID]->size |
| #define DEST_VAR_FLOAT *instr[ip].data.udest.var_float |
| #define DEST_VAR_INT *instr[ip].data.udest.var_int |
| #define DEST_VAR_PTR *instr[ip].data.udest.var_ptr |
| #define INSTR_ADDF_VAR_FLOAT 19 |
| #define INSTR_ADDF_VAR_VAR 20 |
| #define INSTR_ADDI_VAR_INTEGER 17 |
| #define INSTR_ADDI_VAR_VAR 18 |
| #define INSTR_ADDS_VAR_VAR 43 |
| #define INSTR_DIVF_VAR_FLOAT 27 |
| #define INSTR_DIVF_VAR_VAR 28 |
| #define INSTR_DIVI_VAR_INTEGER 25 |
| #define INSTR_DIVI_VAR_VAR 26 |
| #define INSTR_DIVS_VAR_VAR 46 |
| #define INSTR_ISEQUALF_VAR_FLOAT 35 |
| #define INSTR_ISEQUALF_VAR_VAR 34 |
| #define INSTR_ISEQUALI_VAR_INTEGER 33 |
| #define INSTR_ISEQUALI_VAR_VAR 32 |
| #define INSTR_ISEQUALP_VAR_PTR 31 |
| #define INSTR_ISEQUALP_VAR_VAR 30 |
| #define INSTR_ISEQUALS_VAR_VAR 42 |
| #define INSTR_ISLOWERF_VAR_FLOAT 14 |
| #define INSTR_ISLOWERF_VAR_VAR 13 |
| #define INSTR_ISLOWERI_VAR_INTEGER 16 |
| #define INSTR_ISLOWERI_VAR_VAR 15 |
| #define INSTR_MULF_VAR_FLOAT 23 |
| #define INSTR_MULF_VAR_VAR 24 |
| #define INSTR_MULI_VAR_INTEGER 21 |
| #define INSTR_MULI_VAR_VAR 22 |
| #define INSTR_MULS_VAR_VAR 45 |
| #define INSTR_NOP 5 |
| #define INSTR_NOT_VAR 39 |
| #define INSTR_SETF_VAR_FLOAT 3 |
| #define INSTR_SETF_VAR_VAR 4 |
| #define INSTR_SETI_VAR_INTEGER 1 |
| #define INSTR_SETI_VAR_VAR 2 |
| #define INSTR_SETP_VAR_PTR 7 |
| #define INSTR_SETP_VAR_VAR 8 |
| #define INSTR_SETS_VAR_VAR 41 |
| #define INSTR_SUBF_VAR_FLOAT 11 |
| #define INSTR_SUBF_VAR_VAR 12 |
| #define INSTR_SUBI_VAR_INTEGER 9 |
| #define INSTR_SUBI_VAR_VAR 10 |
| #define INSTR_SUBS_VAR_VAR 44 |
| #define JUMP_OFFSET instr[ip].data.udest.jump_offset |
| #define pDEST_VAR instr[ip].data.udest.var |
| #define pSRC_VAR instr[ip].data.usrc.var |
| #define SRC_STRUCT_FBLOCK | ( | i | ) | gsl->gsl_struct[SRC_STRUCT_ID]->fBlock[i] |
| #define SRC_STRUCT_FBLOCK_VAR | ( | i, | |
| j | |||
| ) | ((float*)((char*)pSRC_VAR + gsl->gsl_struct[SRC_STRUCT_ID]->fBlock[i].data))[j] |
| #define SRC_STRUCT_IBLOCK | ( | i | ) | gsl->gsl_struct[SRC_STRUCT_ID]->iBlock[i] |
| #define SRC_STRUCT_IBLOCK_VAR | ( | i, | |
| j | |||
| ) | ((int*)((char*)pSRC_VAR + gsl->gsl_struct[SRC_STRUCT_ID]->iBlock[i].data))[j] |
| #define SRC_STRUCT_ID instr[ip].data.usrc.var_int[-1] |
| #define SRC_VAR_FLOAT *instr[ip].data.usrc.var_float |
| #define SRC_VAR_INT *instr[ip].data.usrc.var_int |
| #define SRC_VAR_PTR *instr[ip].data.usrc.var_ptr |
| #define VALIDATE_ERROR "error while validating " |
| #define VALIDATE_NO_SUCH_DEST_VAR "no such destination variable" |
| #define VALIDATE_NO_SUCH_INT "no such integer variable" |
| #define VALIDATE_NO_SUCH_SRC_VAR "no such src variable" |
| #define VALIDATE_NO_SUCH_VAR "no such variable" |
| #define VALIDATE_SYNTHAX_ERROR "synthax error" |
| #define VALIDATE_TODO "todo" |
| #define VALUE_FLOAT instr[ip].data.usrc.value_float |
| #define VALUE_INT instr[ip].data.usrc.value_int |
| #define VALUE_PTR instr[ip].data.usrc.value_ptr |
|
static |
References _INSTRUCTION::address, _INSTRUCTION::data, goom_hash_get(), HashValue::i, _INSTRUCTION::id, _INSTRUCTION_FLOW::instr, INSTR_NOP, _INSTRUCTION::jump_label, _INSTRUCTION_DATA::jump_offset, _INSTRUCTION_FLOW::labels, _INSTRUCTION::line_number, _INSTRUCTION::nop_label, and _INSTRUCTION_DATA::udest.
Referenced by gsl_compile().
Some native external functions
References GSL_GLOBAL_INT, GSL_LOCAL_INT, GSL_LOCAL_PTR, and NULL.
Referenced by gsl_compile().
References GSL_GLOBAL_INT, and GSL_LOCAL_FLOAT.
Referenced by gsl_compile().
References GSL_GLOBAL_FLOAT, and GSL_LOCAL_INT.
Referenced by gsl_compile().
| void gsl_append_file_to_buffer | ( | const char * | fname, |
| char ** | buffer | ||
| ) |
References gsl_already_imported, gsl_append_file_to_buffer(), gsl_nb_import, and gsl_read_file().
Referenced by gsl_append_file_to_buffer(), and gsl_init_buffer().
| void gsl_bind_function | ( | GoomSL * | gss, |
| const char * | fname, | ||
| GoomSL_ExternalFunction | func | ||
| ) |
References _ExternalFunctionStruct::function, _GoomSL::functions, goom_hash_get(), and HashValue::ptr.
Referenced by gsl_compile().
| void gsl_compile | ( | GoomSL * | _currentGoomSL, |
| const char * | script | ||
| ) |
|
static |
References currentGoomSL, _INSTRUCTION::data, _FAST_INSTRUCTION::data, DEST_STRUCT_FBLOCK, DEST_STRUCT_IBLOCK, DEST_STRUCT_IBLOCK_VAR, DEST_STRUCT_SIZE, _INSTRUCTION_DATA::external_function, _GoomSL::fastiflow, _INSTRUCTION::id, _FAST_INSTRUCTION::id, _GoomSL::iflow, _INSTRUCTION_FLOW::instr, _FastInstructionFlow::instr, INSTR_ADDF_VAR_FLOAT, INSTR_ADDF_VAR_VAR, INSTR_ADDI_VAR_INTEGER, INSTR_ADDI_VAR_VAR, INSTR_ADDS_VAR_VAR, INSTR_CALL, INSTR_DIVF_VAR_FLOAT, INSTR_DIVF_VAR_VAR, INSTR_DIVI_VAR_INTEGER, INSTR_DIVI_VAR_VAR, INSTR_DIVS_VAR_VAR, INSTR_EXT_CALL, INSTR_ISEQUALF_VAR_FLOAT, INSTR_ISEQUALF_VAR_VAR, INSTR_ISEQUALI_VAR_INTEGER, INSTR_ISEQUALI_VAR_VAR, INSTR_ISEQUALP_VAR_PTR, INSTR_ISEQUALP_VAR_VAR, INSTR_ISEQUALS_VAR_VAR, INSTR_ISLOWERF_VAR_FLOAT, INSTR_ISLOWERF_VAR_VAR, INSTR_ISLOWERI_VAR_INTEGER, INSTR_ISLOWERI_VAR_VAR, INSTR_JNZERO, INSTR_JUMP, INSTR_JZERO, INSTR_MULF_VAR_FLOAT, INSTR_MULF_VAR_VAR, INSTR_MULI_VAR_INTEGER, INSTR_MULI_VAR_VAR, INSTR_MULS_VAR_VAR, INSTR_NOP, INSTR_NOT_VAR, INSTR_RET, INSTR_SETF_VAR_FLOAT, INSTR_SETF_VAR_VAR, INSTR_SETI_VAR_INTEGER, INSTR_SETI_VAR_VAR, INSTR_SETP_VAR_PTR, INSTR_SETP_VAR_VAR, INSTR_SETS_VAR_VAR, INSTR_SUBF_VAR_FLOAT, INSTR_SUBF_VAR_VAR, INSTR_SUBI_VAR_INTEGER, INSTR_SUBI_VAR_VAR, INSTR_SUBS_VAR_VAR, _INSTRUCTION::jump_label, _FastInstructionFlow::mallocedInstr, _INSTRUCTION::nop_label, NULL, _INSTRUCTION_FLOW::number, _FastInstructionFlow::number, pDEST_VAR, _FAST_INSTRUCTION::proto, pSRC_VAR, SRC_STRUCT_IBLOCK_VAR, _INSTRUCTION_DATA::udest, _INSTRUCTION_DATA::usrc, _INSTRUCTION_DATA::value_float, _INSTRUCTION_DATA::value_int, _INSTRUCTION_DATA::value_ptr, _INSTRUCTION_DATA::var_float, _INSTRUCTION_DATA::var_int, _INSTRUCTION_DATA::var_ptr, _ExternalFunctionStruct::vars, and _GoomSL::vars.
Referenced by gsl_compile().
| void gsl_declare_external_task | ( | const char * | name | ) |
| void gsl_declare_task | ( | const char * | name | ) |
References currentGoomSL, _ExternalFunctionStruct::function, _GoomSL::functions, goom_hash_get(), goom_hash_new(), goom_hash_put_ptr(), _ExternalFunctionStruct::is_extern, name, and _ExternalFunctionStruct::vars.
Referenced by new_call(), and yyparse().
| void gsl_enternamespace | ( | const char * | name | ) |
References currentGoomSL, _GoomSL::currentNS, function, _GoomSL::functions, goom_hash_get(), name, _GoomSL::namespaces, _GoomSL::num_lines, and HashValue::ptr.
Referenced by yyparse().
| void gsl_execute | ( | GoomSL * | scanner | ) |
References _GoomSL::compilationOK, _GoomSL::fastiflow, and iflow_execute().
| GoomHash* gsl_find_namespace | ( | const char * | name | ) |
References currentGoomSL, _GoomSL::currentNS, goom_hash_get(), name, _GoomSL::namespaces, and NULL.
Referenced by new_call_expr(), and new_var().
| void gsl_free | ( | GoomSL * | gss | ) |
| void gsl_free_ptr | ( | GoomSL * | _this, |
| int | id | ||
| ) |
References _GoomSL::ptrArray.
| void* gsl_get_ptr | ( | GoomSL * | _this, |
| int | id | ||
| ) |
References NULL, and _GoomSL::ptrArray.
References _GoomSL::vars.
| char* gsl_init_buffer | ( | const char * | fname | ) |
References gsl_append_file_to_buffer(), and gsl_nb_import.
| void gsl_instr_add_param | ( | Instruction * | instr, |
| const char * | param, | ||
| int | type | ||
| ) |
References _GoomSL::compilationOK, _INSTRUCTION::cur_param, gsl_instr_display(), gsl_instr_free(), gsl_instr_validate(), _INSTRUCTION::id, _GoomSL::iflow, iflow_add_instr(), INSTR_NOP, NULL, _GoomSL::num_lines, _INSTRUCTION::params, _INSTRUCTION::parent, _INSTRUCTION::types, and VALIDATE_OK.
Referenced by commit_call(), commit_ext_call(), commit_foreach(), commit_function_intro(), commit_function_outro(), commit_node(), commit_not(), GSL_PUT_JUMP(), GSL_PUT_JXXX(), and GSL_PUT_LABEL().
|
static |
References _INSTRUCTION::cur_param, _INSTRUCTION::name, _INSTRUCTION::nb_param, and _INSTRUCTION::params.
Referenced by gsl_instr_add_param(), and iflow_execute().
|
static |
References _INSTRUCTION::cur_param, _VISUAL_FX::free, _INSTRUCTION::params, and _INSTRUCTION::types.
Referenced by gsl_instr_add_param().
| Instruction* gsl_instr_init | ( | GoomSL * | parent, |
| const char * | name, | ||
| int | id, | ||
| int | nb_param, | ||
| int | line_number | ||
| ) |
References _INSTRUCTION::cur_param, _INSTRUCTION::id, _INSTRUCTION::jump_label, _INSTRUCTION::line_number, _INSTRUCTION::name, name, _INSTRUCTION::nb_param, NULL, _INSTRUCTION::params, _INSTRUCTION::parent, _INSTRUCTION::types, and _INSTRUCTION::vnamespace.
Referenced by commit_call(), commit_div_eq(), commit_ext_call(), commit_foreach(), commit_function_intro(), commit_function_outro(), commit_mul_eq(), commit_not(), commit_plus_eq(), commit_sub_eq(), commit_test2(), GSL_PUT_JUMP(), GSL_PUT_JXXX(), GSL_PUT_LABEL(), and precommit_expr().
| void gsl_instr_set_namespace | ( | Instruction * | _this, |
| GoomHash * | ns | ||
| ) |
References _INSTRUCTION::cur_param, _INSTRUCTION::line_number, and _INSTRUCTION::vnamespace.
Referenced by commit_node().
|
static |
References _INSTRUCTION::data, _INSTRUCTION_DATA::external_function, FIRST_RESERVED, _GoomSL::functions, goom_hash_get(), goom_hash_put_int(), gsl_type_of_var(), _INSTRUCTION::id, _GoomSL::iflow, INSTR_ADD, INSTR_ADDF_VAR_FLOAT, INSTR_ADDF_VAR_VAR, INSTR_ADDI_VAR_INTEGER, INSTR_ADDI_VAR_VAR, INSTR_ADDS_VAR_VAR, INSTR_CALL, INSTR_DIV, INSTR_DIVF_VAR_FLOAT, INSTR_DIVF_VAR_VAR, INSTR_DIVI_VAR_INTEGER, INSTR_DIVI_VAR_VAR, INSTR_DIVS_VAR_VAR, INSTR_EXT_CALL, INSTR_FLOAT, INSTR_INT, INSTR_ISEQUAL, INSTR_ISEQUALF_VAR_FLOAT, INSTR_ISEQUALF_VAR_VAR, INSTR_ISEQUALI_VAR_INTEGER, INSTR_ISEQUALI_VAR_VAR, INSTR_ISEQUALP_VAR_PTR, INSTR_ISEQUALP_VAR_VAR, INSTR_ISEQUALS_VAR_VAR, INSTR_ISLOWER, INSTR_ISLOWERF_VAR_FLOAT, INSTR_ISLOWERF_VAR_VAR, INSTR_ISLOWERI_VAR_INTEGER, INSTR_ISLOWERI_VAR_VAR, INSTR_JNZERO, INSTR_JUMP, INSTR_JZERO, INSTR_LABEL, INSTR_MUL, INSTR_MULF_VAR_FLOAT, INSTR_MULF_VAR_VAR, INSTR_MULI_VAR_INTEGER, INSTR_MULI_VAR_VAR, INSTR_MULS_VAR_VAR, INSTR_NOP, INSTR_NOT, INSTR_NOT_VAR, INSTR_PTR, INSTR_RET, INSTR_SET, INSTR_SETF_VAR_FLOAT, INSTR_SETF_VAR_VAR, INSTR_SETI_VAR_INTEGER, INSTR_SETI_VAR_VAR, INSTR_SETP_VAR_PTR, INSTR_SETP_VAR_VAR, INSTR_SETS_VAR_VAR, INSTR_SUB, INSTR_SUBF_VAR_FLOAT, INSTR_SUBF_VAR_VAR, INSTR_SUBI_VAR_INTEGER, INSTR_SUBI_VAR_VAR, INSTR_SUBS_VAR_VAR, _INSTRUCTION::jump_label, _INSTRUCTION_FLOW::labels, _INSTRUCTION::line_number, _INSTRUCTION::nb_param, _INSTRUCTION::nop_label, _INSTRUCTION_FLOW::number, _INSTRUCTION::params, _INSTRUCTION::parent, HashValue::ptr, TYPE_FVAR, TYPE_IVAR, TYPE_LABEL, TYPE_PVAR, TYPE_VAR, _INSTRUCTION::types, _INSTRUCTION_DATA::udest, validate(), VALIDATE_ERROR, VALIDATE_OK, VALIDATE_TODO, and _INSTRUCTION::vnamespace.
Referenced by gsl_instr_add_param().
| int gsl_is_compiled | ( | GoomSL * | gss | ) |
References _GoomSL::compilationOK.
| GoomHash* gsl_leavenamespace | ( | void | ) |
References currentGoomSL, _GoomSL::currentNS, and _GoomSL::namespaces.
Referenced by yyparse().
| int gsl_malloc | ( | GoomSL * | _this, |
| int | size | ||
| ) |
References _GoomSL::nbPtr, _GoomSL::ptrArray, and _GoomSL::ptrArraySize.
Referenced by yylex().
| GoomSL* gsl_new | ( | void | ) |
References _GoomSL::compilationOK, _GoomSL::currentNS, _GoomSL::data_heap, _GoomSL::functions, goom_hash_new(), goom_heap_new(), _GoomSL::gsl_struct, _GoomSL::gsl_struct_size, _GoomSL::iflow, iflow_new(), _GoomSL::namespaces, _GoomSL::nbPtr, _GoomSL::nbStructID, NULL, _GoomSL::ptrArray, _GoomSL::ptrArraySize, reset_scanner(), _GoomSL::structIDS, and _GoomSL::vars.
|
static |
Referenced by gsl_append_file_to_buffer().
| void gsl_reenternamespace | ( | GoomHash * | nsinfo | ) |
References currentGoomSL, _GoomSL::currentNS, and _GoomSL::namespaces.
Referenced by yyparse().
|
static |
References _INSTRUCTION::address, _INSTRUCTION_FLOW::instr, _INSTRUCTION_FLOW::number, and _INSTRUCTION_FLOW::tabsize.
Referenced by gsl_instr_add_param().
|
static |
References goom_hash_free(), goom_hash_new(), _INSTRUCTION_FLOW::labels, and _INSTRUCTION_FLOW::number.
Referenced by reset_scanner().
|
static |
References _FAST_INSTRUCTION::data, DEST_STRUCT_FBLOCK, DEST_STRUCT_FBLOCK_VAR, DEST_STRUCT_IBLOCK, DEST_STRUCT_IBLOCK_VAR, DEST_STRUCT_SIZE, DEST_VAR_FLOAT, DEST_VAR_INT, DEST_VAR_PTR, _INSTRUCTION_DATA::external_function, _ExternalFunctionStruct::function, gsl_instr_display(), _FastInstructionFlow::instr, INSTR_ADDF_VAR_FLOAT, INSTR_ADDF_VAR_VAR, INSTR_ADDI_VAR_INTEGER, INSTR_ADDI_VAR_VAR, INSTR_ADDS_VAR_VAR, INSTR_CALL, INSTR_DIVF_VAR_FLOAT, INSTR_DIVF_VAR_VAR, INSTR_DIVI_VAR_INTEGER, INSTR_DIVI_VAR_VAR, INSTR_DIVS_VAR_VAR, INSTR_EXT_CALL, INSTR_ISEQUALF_VAR_FLOAT, INSTR_ISEQUALF_VAR_VAR, INSTR_ISEQUALI_VAR_INTEGER, INSTR_ISEQUALI_VAR_VAR, INSTR_ISEQUALP_VAR_PTR, INSTR_ISEQUALP_VAR_VAR, INSTR_ISEQUALS_VAR_VAR, INSTR_ISLOWERF_VAR_FLOAT, INSTR_ISLOWERF_VAR_VAR, INSTR_ISLOWERI_VAR_INTEGER, INSTR_ISLOWERI_VAR_VAR, INSTR_JNZERO, INSTR_JUMP, INSTR_JZERO, INSTR_MULF_VAR_FLOAT, INSTR_MULF_VAR_VAR, INSTR_MULI_VAR_INTEGER, INSTR_MULI_VAR_VAR, INSTR_MULS_VAR_VAR, INSTR_NOP, INSTR_NOT_VAR, INSTR_RET, INSTR_SETF_VAR_FLOAT, INSTR_SETF_VAR_VAR, INSTR_SETI_VAR_INTEGER, INSTR_SETI_VAR_VAR, INSTR_SETP_VAR_PTR, INSTR_SETP_VAR_VAR, INSTR_SETS_VAR_VAR, INSTR_SUBF_VAR_FLOAT, INSTR_SUBF_VAR_VAR, INSTR_SUBI_VAR_INTEGER, INSTR_SUBI_VAR_VAR, INSTR_SUBS_VAR_VAR, JUMP_OFFSET, pDEST_VAR, pSRC_VAR, SRC_STRUCT_FBLOCK_VAR, SRC_STRUCT_IBLOCK_VAR, SRC_VAR_FLOAT, SRC_VAR_INT, SRC_VAR_PTR, _INSTRUCTION_DATA::udest, VALUE_FLOAT, VALUE_INT, VALUE_PTR, _ExternalFunctionStruct::vars, and _GoomSL::vars.
Referenced by gsl_execute().
|
static |
References _VISUAL_FX::free, goom_hash_free(), _INSTRUCTION_FLOW::instr, and _INSTRUCTION_FLOW::labels.
Referenced by gsl_free().
|
static |
References goom_hash_new(), _INSTRUCTION_FLOW::instr, _INSTRUCTION_FLOW::labels, _INSTRUCTION_FLOW::number, and _INSTRUCTION_FLOW::tabsize.
Referenced by gsl_new().
|
static |
References _GoomSL::compilationOK, _GoomSL::currentNS, _GoomSL::data_heap, _GSL_Struct::fields, goom_hash_free(), goom_hash_new(), goom_heap_delete(), goom_heap_new(), _GoomSL::gsl_struct, _GoomSL::iflow, iflow_clean(), _GoomSL::instr, _GoomSL::namespaces, _GSL_Struct::nbFields, _GoomSL::nbStructID, NULL, _GoomSL::num_lines, _GoomSL::structIDS, and _GoomSL::vars.
Referenced by gsl_compile(), and gsl_new().
|
static |
References FIRST_RESERVED, _INSTRUCTION::id, INSTR_NOP, TYPE_FLOAT, TYPE_FVAR, TYPE_INTEGER, TYPE_IVAR, TYPE_PTR, TYPE_PVAR, _INSTRUCTION::types, VALIDATE_ERROR, validate_v_f(), validate_v_i(), validate_v_p(), and validate_v_v().
Referenced by gsl_instr_validate().
|
static |
|
static |
|
static |
|
static |
| void yy_scan_string | ( | const char * | str | ) |
Referenced by gsl_compile().
| int yyparse | ( | void | ) |
Referenced by gsl_compile().
|
static |
Referenced by gsl_append_file_to_buffer().
|
static |
Referenced by gsl_append_file_to_buffer(), and gsl_init_buffer().
|
static |
Referenced by gsl_instr_add_param(), gsl_instr_validate(), validate_v_f(), validate_v_i(), validate_v_p(), and validate_v_v().
1.8.17