C:/Users/Dennis/src/lang/russell.orig/src/delab/delab.c File Reference

#include <stdio.h>
#include <strings.h>
#include "codegen.h"
#include "op_codes.h"

Go to the source code of this file.

Data Structures

struct  instr
struct  fwd_ref

Defines

#define TRUE   1
#define FALSE   0
#define MAX_TEMP_LAB   20
#define REF   0
#define DEF   1
#define FWD   0
#define BCK   1
#define dbg_msg(x)
#define dbg_msg2(s, x)
#define dbg_msg3(s, x, y)
#define dbg_msg4(s, x, y, z)

Functions

 main (int argc, char **argv)
 save_it (struct instr *newone, int opc, arg, char *label_buf)
int next_opc ()
int normal_label (int opc, char *p)
 put_reg_op (int opc, arg)
 put_lbl_op (int opc, char *label)
char * fixit (char *str)
 usage (char *name)

Variables

int last_type
int last_num
int last_dir
struct instrinstr_list = (struct instr *) 0
struct instrtail_il = (struct instr *) 0
struct fwd_reffwd_refs [MAX_TEMP_LAB+1]
char * op_code_table []
char label_buf [MAXLABELSZ+1]
char save_label [MAXLABELSZ+1]
char * crud [20]
char * cur_name [MAX_TEMP_LAB+1]
int num_fwd_refs = 0
int lbl_num = 0
int read_ahead = FALSE
int saved_opc
FILE * in_file
FILE * out_file


Define Documentation

#define BCK   1

Definition at line 48 of file delab.c.

Referenced by normal_label().

#define dbg_msg (  ) 

Definition at line 109 of file delab.c.

Referenced by main(), and save_it().

#define dbg_msg2 ( s,
 ) 

Definition at line 110 of file delab.c.

Referenced by main(), normal_label(), and save_it().

#define dbg_msg3 ( s,
x,
 ) 

Definition at line 111 of file delab.c.

Referenced by main(), and normal_label().

#define dbg_msg4 ( s,
x,
y,
 ) 

Definition at line 112 of file delab.c.

Referenced by main(), and save_it().

#define DEF   1

Definition at line 42 of file delab.c.

Referenced by main(), and normal_label().

#define FALSE   0

Definition at line 37 of file delab.c.

Referenced by add_id_fv(), add_objfile(), amatch(), bld_analyze(), C_name(), calls_callcc(), calls_put(), checksigs(), cl_analyze(), clear_construction(), clear_equiv(), clear_slink_known(), comp1_st(), comp_st(), compile_decl(), compile_while_loop(), declsig(), def_match(), delcomp(), dl_match(), eliminate(), eval_decl(), find_equiv_regs(), findapplsig(), finddecl(), finddecl1(), findidsig(), findmpsig(), findsig(), findstdecl(), finish_idt(), fix_array_sig(), fixhints(), Gappl(), Garg_expression(), GC_allochblk(), GC_block_empty(), GC_collect_or_expand(), GC_continue_reclaim(), GC_expand_hp_inner(), GC_gcollect_inner(), GC_has_debug_info(), GC_mark_reliable(), GC_reclaim_block(), Gcompile_funcs(), gen_special(), getcomp(), Gexpression(), Gfunc_body(), Gfuncconstructor(), Ggen_special(), Ggeneratecode(), Ggeneratepcode(), GgenerateXcode(), Gheap_expression(), Gident(), Gpush_size(), Gtraverse(), hascomp(), hasstring(), import(), impure(), infer_args(), is_const(), is_const_init(), is_int_const(), is_int_const1(), is_selected_id(), is_this_arg(), main(), make_instr(), maprl1_non_vacuous(), mentions_r11(), n_vacuous_params(), needs_new_nonl(), normal_label(), only_indirect_ref(), outermost_op(), parse_RIC(), propagate(), replace_arg(), roots_present(), set_regs(), sigids(), solve(), stt_enter(), subst1(), tl_checksigs(), trivial(), tsubst1(), type_constr(), unparse(), unshare1(), vacuous_arg(), valid_C_id(), Vallocate(), Vallocwalk(), Vappl(), Vfuncbody(), Vfuncconstructor(), Vgeneratecode(), Vnewreg(), wl_has_comp(), and yylex().

#define FWD   0

Definition at line 47 of file delab.c.

Referenced by main(), and normal_label().

#define MAX_TEMP_LAB   20

Definition at line 38 of file delab.c.

#define REF   0

Definition at line 41 of file delab.c.

Referenced by normal_label().

#define TRUE   1

Definition at line 36 of file delab.c.

Referenced by accessible(), add_id_fv(), add_idt(), add_objfile(), amatch(), bld_analyze(), body_accessible(), C_name(), check_vacuous(), checksigs(), cl_analyze(), clear_construction(), clear_equiv(), coerce(), comp1_st(), copy_RIC(), def_match(), delcomp(), dl_match(), eliminate(), equiv_expr(), eval_decl(), expand_str(), Ffuncbody(), find_equiv_regs(), find_forward_refs(), finddecl(), finddecl1(), findidsig(), findmpsig(), findsig(), findstdecl(), fixhints(), Gappl(), GC_allochblk(), GC_block_empty(), GC_collect_or_expand(), GC_debug_malloc(), GC_debug_malloc_atomic(), GC_disable_signals(), GC_expand_hp_inner(), GC_gcollect(), GC_gcollect_inner(), GC_has_debug_info(), GC_normal_mark_proc(), GC_reclaim_block(), GC_register_displacement_inner(), Gcompile_funcs(), gen_special(), get_complexity(), get_name(), getcomp(), Gexpression(), Gfunc_body(), Ggen_special(), Ggeneratecode(), Ggeneratepcode(), GgenerateXcode(), Gpush_size(), hascomp(), hasstring(), import(), impure(), infer_args(), inscomp(), is_const(), is_int_const1(), is_selected_id(), is_this_arg(), is_unique(), main(), make_lbl_instr(), mentions_r11(), mk_put_selection(), mkcompnm(), needs_new_nonl(), next_opc(), normal_label(), only_indirect_ref(), parse_RIC(), propagate(), replace_arg(), roots_present(), set_regs(), sig_in1(), sigids(), solve(), stt_enter(), subst1(), trivial(), tsubst1(), unparse(), unshare1(), vacuous_arg(), valid_C_id(), Vallocate(), Vallocwalk(), Vappl(), Vgeneratecode(), Vgeneratepcode(), Vretreg(), and wl_has_comp().


Function Documentation

char* fixit ( char *  str  ) 

Definition at line 461 of file delab.c.

References malloc.

Referenced by put_lbl_op().

main ( int  argc,
char **  argv 
)

Definition at line 118 of file delab.c.

References instr::arg, crud, cur_name, dbg_msg, dbg_msg2, dbg_msg3, dbg_msg4, DEF, FALSE, free, FWD, in_file, fwd_ref::inst, instr::label, label_buf, last_dir, last_num, last_type, LBA, lbl_num, malloc, MAX_LABEL_OP, MAXLABELSZ, N_OP_CODES, instr::next, fwd_ref::next, normal_label(), num_fwd_refs, op_code_table, instr::opc, out_file, put_lbl_op(), put_reg_op(), read_ahead, save_it(), save_label, saved_opc, TRUE, and usage().

int next_opc (  ) 

Definition at line 384 of file delab.c.

References in_file, read_ahead, saved_opc, and TRUE.

Referenced by normal_label().

int normal_label ( int  opc,
char *  p 
)

Definition at line 398 of file delab.c.

References BCK, dbg_msg2, dbg_msg3, DEF, FALSE, FWD, last_dir, last_num, last_type, LBA, LBL, LDS, next_opc(), op_code_table, REF, and TRUE.

Referenced by main().

put_lbl_op ( int  opc,
char *  label 
)

Definition at line 448 of file delab.c.

References fixit(), and out_file.

Referenced by main().

put_reg_op ( int  opc,
arg   
)

Definition at line 434 of file delab.c.

References out_file.

Referenced by main().

save_it ( struct instr newone,
int  opc,
arg  ,
char *  label_buf 
)

Definition at line 345 of file delab.c.

References instr::arg, dbg_msg, dbg_msg2, dbg_msg4, instr::label, malloc, MAXLABELSZ, instr::next, op_code_table, and instr::opc.

Referenced by main().

usage ( char *  name  ) 

Definition at line 486 of file delab.c.

Referenced by main().


Variable Documentation

char* crud[20]

Definition at line 82 of file delab.c.

Referenced by main().

char* cur_name[MAX_TEMP_LAB+1]

Initial value:

 
        { "..............", "..............", "..............",
          "..............", "..............", "..............",
          "..............", "..............", "..............",
          "..............", "..............", "..............",
          "..............", "..............", "..............",
          "..............", "..............", "..............",
          "..............", ".............." }

Definition at line 85 of file delab.c.

Referenced by main().

struct fwd_ref* fwd_refs[MAX_TEMP_LAB+1]

Initial value:

        { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }

Definition at line 73 of file delab.c.

FILE* in_file

Definition at line 99 of file delab.c.

Referenced by main(), and next_opc().

struct instr* instr_list = (struct instr *) 0

Definition at line 60 of file delab.c.

char label_buf[MAXLABELSZ+1]

Definition at line 79 of file delab.c.

Referenced by get_RIC(), main(), and read_instr().

int last_dir

Definition at line 46 of file delab.c.

Referenced by main(), and normal_label().

int last_num

Definition at line 44 of file delab.c.

Referenced by main(), and normal_label().

int last_type

Definition at line 40 of file delab.c.

Referenced by main(), and normal_label().

int lbl_num = 0

Definition at line 95 of file delab.c.

Referenced by main().

int num_fwd_refs = 0

Definition at line 94 of file delab.c.

Referenced by main().

char* op_code_table[]

Definition at line 4 of file op_codes.c.

Referenced by init_RIC_table(), main(), normal_label(), save_it(), and unindirect().

FILE * out_file

Definition at line 99 of file delab.c.

Referenced by main(), put_lbl_op(), and put_reg_op().

int read_ahead = FALSE

Definition at line 96 of file delab.c.

Referenced by main(), and next_opc().

char save_label[MAXLABELSZ+1]

Definition at line 80 of file delab.c.

Referenced by main().

int saved_opc

Definition at line 97 of file delab.c.

Referenced by main(), and next_opc().

struct instr* tail_il = (struct instr *) 0

Definition at line 62 of file delab.c.


Generated on Fri Jan 25 10:39:48 2008 for russell by  doxygen 1.5.4