pike.git / src / interpret_functions.h

version» Context lines:

pike.git/src/interpret_functions.h:257:    push_svalue(& Pike_fp->context->prog->constants[arg1].sval);    print_return_value();   });         /* Generic swap instruction:    * swaps the arg1 top values with the arg2 values beneath    */   OPCODE2(F_REARRANGE,"rearrange",0,{    check_stack(arg2); -  MEMCPY(Pike_sp,Pike_sp-arg1-arg2,sizeof(struct svalue)*arg2); -  MEMMOVE(Pike_sp-arg1-arg2,Pike_sp-arg1,sizeof(struct svalue)*arg1); -  MEMCPY(Pike_sp-arg2,Pike_sp,sizeof(struct svalue)*arg2); +  memcpy(Pike_sp,Pike_sp-arg1-arg2,sizeof(struct svalue)*arg2); +  memmove(Pike_sp-arg1-arg2,Pike_sp-arg1,sizeof(struct svalue)*arg1); +  memcpy(Pike_sp-arg2,Pike_sp,sizeof(struct svalue)*arg2);   });      /* The rest of the basic 'push value' instructions */      OPCODE1_TAIL(F_MARK_AND_STRING, "mark & string", I_UPDATE_SP|I_UPDATE_M_SP, {    *(Pike_mark_sp++)=Pike_sp;       OPCODE1(F_STRING, "string", I_UPDATE_SP, {    ref_push_string(Pike_fp->context->prog->strings[arg1]);    print_return_value();
pike.git/src/interpret_functions.h:1908:      /* Used with F_LTOSVAL*_AND_FREE - must not release interpreter lock. */   OPCODE0_ALIAS(F_SUBTRACT, "-", I_UPDATE_SP, o_subtract);   OPCODE0_ALIAS(F_AND, "&", I_UPDATE_SP, o_and);   OPCODE0_ALIAS(F_OR, "|", I_UPDATE_SP, o_or);   OPCODE0_ALIAS(F_XOR, "^", I_UPDATE_SP, o_xor);   OPCODE0_ALIAS(F_MULTIPLY, "*", I_UPDATE_SP, o_multiply);   OPCODE0_ALIAS(F_DIVIDE, "/", I_UPDATE_SP, o_divide);   OPCODE0_ALIAS(F_MOD, "%", I_UPDATE_SP, o_mod);    + OPCODE1(F_SUBTRACT_INT, "- int", 0, { +  push_int( arg1 ); +  o_subtract(); + }); +  + OPCODE1(F_AND_INT, "& int", 0, { +  push_int( arg1 ); +  o_and(); + }); +  + OPCODE1(F_OR_INT, "| int", 0, { +  push_int( arg1 ); +  o_or(); + }); +  + OPCODE1(F_XOR_INT, "^ int", 0, { +  push_int( arg1 ); +  o_xor(); + }); +  + OPCODE1(F_MULTIPLY_INT, "* int", 0, { +  push_int( arg1 ); +  o_multiply(); + }); +  + OPCODE1(F_DIVIDE_INT, "/ int", 0, { +  push_int( arg1 ); +  o_divide(); + }); +  + OPCODE1(F_MOD_INT, "% int", 0, { +  push_int( arg1 ); +  o_mod(); + }); +  + OPCODE1(F_RSH_INT, ">> int", 0, { +  push_int( arg1 ); +  o_rsh(); + }); +  + OPCODE1(F_LSH_INT, "<< int", 0, { +  push_int( arg1 ); +  o_lsh(); + }); +    OPCODE1(F_ADD_INT, "add integer", 0, {    if(TYPEOF(Pike_sp[-1]) == T_INT    && !INT_TYPE_ADD_OVERFLOW(Pike_sp[-1].u.integer, arg1))    {    Pike_sp[-1].u.integer+=arg1;    SET_SVAL_SUBTYPE(Pike_sp[-1], NUMBER_NUMBER); /* Could have UNDEFINED there before. */    }else{    push_int(arg1);    f_add(2);    }