pike.git / src / interpret.c

version» Context lines:

pike.git/src/interpret.c:906: Inside #if defined(HAVE_COMPUTED_GOTO)
  #ifdef HAVE_COMPUTED_GOTO    if (instr)    ADD_RUNNED(instr);    else    Pike_fatal("NULL Instruction!\n");   #else /* !HAVE_COMPUTED_GOTO */    if(instr + F_OFFSET < F_MAX_OPCODE)    ADD_RUNNED(instr);   #endif /* HAVE_COMPUTED_GOTO */    -  if(d_flag) +  if(d_flag )    {    backlogp++;    if(backlogp >= BACKLOG) backlogp=0;       backlog[backlogp].program_id = Pike_fp->context->prog->id;    backlog[backlogp].instruction=instr;    backlog[backlogp].pc = Pike_fp->pc;    backlog[backlogp].stack = Pike_sp - Pike_interpreter.evaluator_stack;    backlog[backlogp].mark_stack = Pike_mark_sp - Pike_interpreter.mark_stack;   #ifdef _REENTRANT
pike.git/src/interpret.c:949:    if(Pike_mark_sp > Pike_interpreter.mark_stack+Pike_stack_size)    Pike_fatal("Mark Stack error (overflow).\n");          if(Pike_mark_sp < Pike_interpreter.mark_stack)    Pike_fatal("Mark Stack error (underflow).\n");       if(Pike_sp > Pike_interpreter.evaluator_stack+Pike_stack_size)    Pike_fatal("stack error (overflow).\n");    +  +  /* The locals will not be correct when running FILL_STACK +  (actually, they will always be incorrect before running FILL_STACK, +  but at least currently that is the first opcode run). +  */ +  if( instr+F_OFFSET != F_FILL_STACK ) +  {    if(/* Pike_fp->fun>=0 && */ Pike_fp->current_object->prog &&    Pike_fp->locals+Pike_fp->num_locals > Pike_sp) -  Pike_fatal("Stack error (stupid!).\n"); +  Pike_fatal("Stack error (stupid! %p %p+%x).\n",Pike_sp, +  Pike_fp->locals, Pike_fp->num_locals*sizeof(struct svalue)); +  }       if(Pike_interpreter.recoveries &&    (Pike_sp-Pike_interpreter.evaluator_stack <    Pike_interpreter.recoveries->stack_pointer))    Pike_fatal("Stack error (underflow).\n");       if(Pike_mark_sp > Pike_interpreter.mark_stack &&    Pike_mark_sp[-1] > Pike_sp)    Pike_fatal("Stack error (underflow?)\n");   
pike.git/src/interpret.c:2836:    ret = 1;    }       UNSETJMP(recovery);       STACK_LEVEL_DONE(ret);       return ret;   }    - PMOD_EXPORT void apply_lfun(struct object *o, int fun, int args) + PMOD_EXPORT void apply_lfun(struct object *o, int lfun, int args)   { -  +  int fun;   #ifdef PIKE_DEBUG -  if(fun < 0 || fun >= NUM_LFUNS) +  if(lfun < 0 || lfun >= NUM_LFUNS)    Pike_fatal("Apply lfun on illegal value!\n");   #endif    if(!o->prog) -  PIKE_ERROR("destructed object", "Apply on destructed object.\n", Pike_sp, args); +  PIKE_ERROR("destructed object", "Apply on destructed object.\n", +  Pike_sp, args);    -  apply_low(o, (int)FIND_LFUN(o->prog,fun), args); +  if ((fun = (int)FIND_LFUN(o->prog, lfun)) < 0) +  Pike_error("Calling undefined lfun::%s.\n", lfun_names[lfun]); +  +  apply_low(o, fun, args);   }      PMOD_EXPORT void apply_shared(struct object *o,    struct pike_string *fun,    int args)   {    int id = find_shared_string_identifier(fun, o->prog);    if (id >= 0)    apply_low(o, id, args);    else