pike.git / src / peep.c

version» Context lines:

pike.git/src/peep.c:5:   #include "program.h"   #include "las.h"   #include "docode.h"   #include "main.h"   #include "error.h"   #include "lex.h"   #include "pike_memory.h"   #include "peep.h"   #include "dmalloc.h"    - RCSID("$Id: peep.c,v 1.19 1998/03/28 15:11:56 grubba Exp $"); + RCSID("$Id: peep.c,v 1.20 1998/03/31 21:52:23 hubbe Exp $");      struct p_instr_s   {    short opcode;    short line;    struct pike_string *file;    INT32 arg;   };      typedef struct p_instr_s p_instr;
pike.git/src/peep.c:251:    {    case F_NOP: break;    case F_ALIGN:    while(PC % c->arg) add_to_program(0);    break;       case F_BYTE:    add_to_program(c->arg);    break;    +  case F_DATA: +  ins_int(c->arg, (void(*)(char))add_to_program); +  break; +     case F_LABEL:   #ifdef DEBUG    if(c->arg > max_label || c->arg < 0)    fatal("max_label calculation failed!\n");       if(labels[c->arg] != -1)    fatal("Duplicate label!\n");   #endif    labels[c->arg]=PC;    break;
pike.git/src/peep.c:338: Inside #if defined(DEBUG)
   if(!hasarg(f) && b)    fatal("hasarg() is wrong!\n");   #endif       p=(p_instr *)low_make_buf_space(sizeof(p_instr), &instrbuf);       if(fifo_len)    {    MEMMOVE(p-fifo_len+1,p-fifo_len,fifo_len*sizeof(p_instr));    p-=fifo_len; -  fifo_len++; +     }      #ifdef DEBUG    if(!instrbuf.s.len)    fatal("Low make buf space failed!!!!!!\n");   #endif       p->opcode=f;    p->line=cl;    copy_shared_string(p->file, lex.current_file);
pike.git/src/peep.c:360:       return p - (p_instr *)instrbuf.s.str;   }      int insopt2(int f, int cl, struct pike_string *cf)   {   #ifdef DEBUG    if(hasarg(f))    fatal("hasarg() is wrong!\n");   #endif -  return insert_opcode(f,0,cl, cf); +  return insopt(f,0,cl, cf);   }         static void debug(void)   {    if(fifo_len > (long)instrbuf.s.len / (long)sizeof(p_instr))    fifo_len=(long)instrbuf.s.len / (long)sizeof(p_instr);   #ifdef DEBUG    if(eye < 0)    fatal("Popped beyond start of code.\n");