ParserUtil - Parser support functions.
- iNew()
* P = new type, [init]
* PASM like:
* new P, .SomeThing
* is done in the lexer, this is a mess
* best would be to have a flag in core.ops, where a PMC type is expected
- op_fullname()
- Lookup the full opcode given the short name
set I0, 5 -> set_i_ic
set I0, I1 -> set_i_i
- Obviously the registers must be examined before returning the correct opcode.
- NOTE: All this nasty IMC_TRACE is for tracking down equally nasty bugs, so if you don't like the looks of it, stay out, but please don't remove it. :) -Mel
check_op()
- Return opcode value for op name
maybe_builtin()
- Needs to be documented!!!
is_op()
- Is instruction a parrot opcode?
to_infix()
- Needs to be documented!!!
- sub x, y, z => infix .MMD_SUBTRACT, x, y, z
is_infix()
- Needs to be documented!!!
var_arg_ins()
- Needs to be documented!!!
INS()
- Make an instruction.
- name ... op name fmt ... optional format regs ... SymReg ** n ... # of params keyvec ... s. KEY_BIT() emit ... if true, append to instructions
- s. e.g. imc.c for usage
do_yylex_init()
- Needs to be documented!!!
PMC *imcc_compile(interp*, const char*)
- Compile a pasm or imcc string
- FIXME as we have separate constants, the old constants in ghash must be deleted.
imcc_compile_pasm()
- Needs to be documented!!!
* Note: This function is provided for backward compatibility. This
* function can go away in future.
imcc_compile_pir()
- Needs to be documented!!!
* Note: This function is provided for backward compatibility. This
* function can go away in future.
IMCC_compile_pir_s()
- Needs to be documented!!!
IMCC_compile_pasm_s()
- Needs to be documented!!!
imcc_compile_pasm_ex()
- Needs to be documented!!!
imcc_compile_pir_ex()
- Needs to be documented!!!
imcc_compile_file()
- Compile a file by filename (can be either PASM or IMCC code)
IMCC_compile_file()
- Needs to be documented!!!
* Note: This function is provided for backward compatibility. This
* function can go away in future.
IMCC_compile_file_s()
- Needs to be documented!!!
register_compilers()
- Register additional compilers with the interpreter
change_op()
- Needs to be documented!!!
try_find_op()
- Try to find valid op doing the same operation e.g.
add_n_i_n => add_n_n_i
div_n_ic_n => div_n_nc_n
div_n_i_n => set_n_i ; div_n_n_n
ge_n_ic_ic => ge_n_nc_ic
acos_n_i => acos_n_n
try_rev_cmp()
- Needs to be documented!!!
multi_keyed()
- Needs to be documented!!!
imcc_fprintf()
- Needs to be documented!!!
imcc_vfprintf()
- Needs to be documented!!!
str_dup()
- Needs to be documented!!!
imcc_init()
- Needs to be documented!!!
imcc_destroy()
- Needs to be documented!!!