2 * Copyright (c) 1996-1998 Malcolm Beattie
4 * You may distribute under the terms of either the GNU General Public
5 * License or the Artistic License, as specified in the README file.
9 * This file is autogenerated from bytecode.pl. Changes made here will be lost.
16 bset_obj_store(void *obj, I32 ix)
18 if (ix > PL_bytecode_obj_list_fill) {
19 if (PL_bytecode_obj_list_fill == -1)
20 New(666, PL_bytecode_obj_list, ix + 1, void*);
22 Renew(PL_bytecode_obj_list, ix + 1, void*);
23 PL_bytecode_obj_list_fill = ix;
25 PL_bytecode_obj_list[ix] = obj;
29 #ifdef INDIRECT_BGET_MACROS
30 void byterun(struct bytestream bs)
32 void byterun(PerlIO *fp)
33 #endif /* INDIRECT_BGET_MACROS */
37 while ((insn = BGET_FGETC()) != EOF) {
39 case INSN_COMMENT: /* 35 */
46 case INSN_NOP: /* 10 */
50 case INSN_RET: /* 0 */
55 case INSN_LDSV: /* 1 */
62 case INSN_LDOP: /* 2 */
69 case INSN_STSV: /* 3 */
73 BSET_OBJ_STORE(PL_bytecode_sv, arg);
76 case INSN_STOP: /* 4 */
80 BSET_OBJ_STORE(PL_op, arg);
83 case INSN_LDSPECSV: /* 5 */
87 BSET_ldspecsv(PL_bytecode_sv, arg);
90 case INSN_NEWSV: /* 6 */
94 BSET_newsv(PL_bytecode_sv, arg);
97 case INSN_NEWOP: /* 7 */
101 BSET_newop(PL_op, arg);
104 case INSN_NEWOPN: /* 8 */
108 BSET_newopn(PL_op, arg);
111 case INSN_NEWPV: /* 9 */
117 case INSN_PV_CUR: /* 11 */
121 PL_bytecode_pv.xpv_cur = arg;
124 case INSN_PV_FREE: /* 12 */
126 BSET_pv_free(PL_bytecode_pv);
129 case INSN_SV_UPGRADE: /* 13 */
133 BSET_sv_upgrade(PL_bytecode_sv, arg);
136 case INSN_SV_REFCNT: /* 14 */
140 SvREFCNT(PL_bytecode_sv) = arg;
143 case INSN_SV_REFCNT_ADD: /* 15 */
147 BSET_sv_refcnt_add(SvREFCNT(PL_bytecode_sv), arg);
150 case INSN_SV_FLAGS: /* 16 */
154 SvFLAGS(PL_bytecode_sv) = arg;
157 case INSN_XRV: /* 17 */
161 SvRV(PL_bytecode_sv) = arg;
164 case INSN_XPV: /* 18 */
166 BSET_xpv(PL_bytecode_sv);
169 case INSN_XIV32: /* 19 */
173 SvIVX(PL_bytecode_sv) = arg;
176 case INSN_XIV64: /* 20 */
180 SvIVX(PL_bytecode_sv) = arg;
183 case INSN_XNV: /* 21 */
187 SvNVX(PL_bytecode_sv) = arg;
190 case INSN_XLV_TARGOFF: /* 22 */
194 LvTARGOFF(PL_bytecode_sv) = arg;
197 case INSN_XLV_TARGLEN: /* 23 */
201 LvTARGLEN(PL_bytecode_sv) = arg;
204 case INSN_XLV_TARG: /* 24 */
208 LvTARG(PL_bytecode_sv) = arg;
211 case INSN_XLV_TYPE: /* 25 */
215 LvTYPE(PL_bytecode_sv) = arg;
218 case INSN_XBM_USEFUL: /* 26 */
222 BmUSEFUL(PL_bytecode_sv) = arg;
225 case INSN_XBM_PREVIOUS: /* 27 */
229 BmPREVIOUS(PL_bytecode_sv) = arg;
232 case INSN_XBM_RARE: /* 28 */
236 BmRARE(PL_bytecode_sv) = arg;
239 case INSN_XFM_LINES: /* 29 */
243 FmLINES(PL_bytecode_sv) = arg;
246 case INSN_XIO_LINES: /* 30 */
250 IoLINES(PL_bytecode_sv) = arg;
253 case INSN_XIO_PAGE: /* 31 */
257 IoPAGE(PL_bytecode_sv) = arg;
260 case INSN_XIO_PAGE_LEN: /* 32 */
264 IoPAGE_LEN(PL_bytecode_sv) = arg;
267 case INSN_XIO_LINES_LEFT: /* 33 */
271 IoLINES_LEFT(PL_bytecode_sv) = arg;
274 case INSN_XIO_TOP_NAME: /* 34 */
277 BGET_pvcontents(arg);
278 IoTOP_NAME(PL_bytecode_sv) = arg;
281 case INSN_XIO_TOP_GV: /* 36 */
285 *(SV**)&IoTOP_GV(PL_bytecode_sv) = arg;
288 case INSN_XIO_FMT_NAME: /* 37 */
291 BGET_pvcontents(arg);
292 IoFMT_NAME(PL_bytecode_sv) = arg;
295 case INSN_XIO_FMT_GV: /* 38 */
299 *(SV**)&IoFMT_GV(PL_bytecode_sv) = arg;
302 case INSN_XIO_BOTTOM_NAME: /* 39 */
305 BGET_pvcontents(arg);
306 IoBOTTOM_NAME(PL_bytecode_sv) = arg;
309 case INSN_XIO_BOTTOM_GV: /* 40 */
313 *(SV**)&IoBOTTOM_GV(PL_bytecode_sv) = arg;
316 case INSN_XIO_SUBPROCESS: /* 41 */
320 IoSUBPROCESS(PL_bytecode_sv) = arg;
323 case INSN_XIO_TYPE: /* 42 */
327 IoTYPE(PL_bytecode_sv) = arg;
330 case INSN_XIO_FLAGS: /* 43 */
334 IoFLAGS(PL_bytecode_sv) = arg;
337 case INSN_XCV_STASH: /* 44 */
341 *(SV**)&CvSTASH(PL_bytecode_sv) = arg;
344 case INSN_XCV_START: /* 45 */
348 CvSTART(PL_bytecode_sv) = arg;
351 case INSN_XCV_ROOT: /* 46 */
355 CvROOT(PL_bytecode_sv) = arg;
358 case INSN_XCV_GV: /* 47 */
362 *(SV**)&CvGV(PL_bytecode_sv) = arg;
365 case INSN_XCV_FILEGV: /* 48 */
369 *(SV**)&CvFILEGV(PL_bytecode_sv) = arg;
372 case INSN_XCV_DEPTH: /* 49 */
376 CvDEPTH(PL_bytecode_sv) = arg;
379 case INSN_XCV_PADLIST: /* 50 */
383 *(SV**)&CvPADLIST(PL_bytecode_sv) = arg;
386 case INSN_XCV_OUTSIDE: /* 51 */
390 *(SV**)&CvOUTSIDE(PL_bytecode_sv) = arg;
393 case INSN_XCV_FLAGS: /* 52 */
397 CvFLAGS(PL_bytecode_sv) = arg;
400 case INSN_AV_EXTEND: /* 53 */
404 BSET_av_extend(PL_bytecode_sv, arg);
407 case INSN_AV_PUSH: /* 54 */
411 BSET_av_push(PL_bytecode_sv, arg);
414 case INSN_XAV_FILL: /* 55 */
418 AvFILLp(PL_bytecode_sv) = arg;
421 case INSN_XAV_MAX: /* 56 */
425 AvMAX(PL_bytecode_sv) = arg;
428 case INSN_XAV_FLAGS: /* 57 */
432 AvFLAGS(PL_bytecode_sv) = arg;
435 case INSN_XHV_RITER: /* 58 */
439 HvRITER(PL_bytecode_sv) = arg;
442 case INSN_XHV_NAME: /* 59 */
445 BGET_pvcontents(arg);
446 HvNAME(PL_bytecode_sv) = arg;
449 case INSN_HV_STORE: /* 60 */
453 BSET_hv_store(PL_bytecode_sv, arg);
456 case INSN_SV_MAGIC: /* 61 */
460 BSET_sv_magic(PL_bytecode_sv, arg);
463 case INSN_MG_OBJ: /* 62 */
467 SvMAGIC(PL_bytecode_sv)->mg_obj = arg;
470 case INSN_MG_PRIVATE: /* 63 */
474 SvMAGIC(PL_bytecode_sv)->mg_private = arg;
477 case INSN_MG_FLAGS: /* 64 */
481 SvMAGIC(PL_bytecode_sv)->mg_flags = arg;
484 case INSN_MG_PV: /* 65 */
487 BGET_pvcontents(arg);
488 BSET_mg_pv(SvMAGIC(PL_bytecode_sv), arg);
491 case INSN_XMG_STASH: /* 66 */
495 *(SV**)&SvSTASH(PL_bytecode_sv) = arg;
498 case INSN_GV_FETCHPV: /* 67 */
502 BSET_gv_fetchpv(PL_bytecode_sv, arg);
505 case INSN_GV_STASHPV: /* 68 */
509 BSET_gv_stashpv(PL_bytecode_sv, arg);
512 case INSN_GP_SV: /* 69 */
516 GvSV(PL_bytecode_sv) = arg;
519 case INSN_GP_REFCNT: /* 70 */
523 GvREFCNT(PL_bytecode_sv) = arg;
526 case INSN_GP_REFCNT_ADD: /* 71 */
530 BSET_gp_refcnt_add(GvREFCNT(PL_bytecode_sv), arg);
533 case INSN_GP_AV: /* 72 */
537 *(SV**)&GvAV(PL_bytecode_sv) = arg;
540 case INSN_GP_HV: /* 73 */
544 *(SV**)&GvHV(PL_bytecode_sv) = arg;
547 case INSN_GP_CV: /* 74 */
551 *(SV**)&GvCV(PL_bytecode_sv) = arg;
554 case INSN_GP_FILEGV: /* 75 */
558 *(SV**)&GvFILEGV(PL_bytecode_sv) = arg;
561 case INSN_GP_IO: /* 76 */
565 *(SV**)&GvIOp(PL_bytecode_sv) = arg;
568 case INSN_GP_FORM: /* 77 */
572 *(SV**)&GvFORM(PL_bytecode_sv) = arg;
575 case INSN_GP_CVGEN: /* 78 */
579 GvCVGEN(PL_bytecode_sv) = arg;
582 case INSN_GP_LINE: /* 79 */
586 GvLINE(PL_bytecode_sv) = arg;
589 case INSN_GP_SHARE: /* 80 */
593 BSET_gp_share(PL_bytecode_sv, arg);
596 case INSN_XGV_FLAGS: /* 81 */
600 GvFLAGS(PL_bytecode_sv) = arg;
603 case INSN_OP_NEXT: /* 82 */
607 PL_op->op_next = arg;
610 case INSN_OP_SIBLING: /* 83 */
614 PL_op->op_sibling = arg;
617 case INSN_OP_PPADDR: /* 84 */
621 BSET_op_ppaddr(PL_op->op_ppaddr, arg);
624 case INSN_OP_TARG: /* 85 */
628 PL_op->op_targ = arg;
631 case INSN_OP_TYPE: /* 86 */
635 BSET_op_type(PL_op, arg);
638 case INSN_OP_SEQ: /* 87 */
645 case INSN_OP_FLAGS: /* 88 */
649 PL_op->op_flags = arg;
652 case INSN_OP_PRIVATE: /* 89 */
656 PL_op->op_private = arg;
659 case INSN_OP_FIRST: /* 90 */
663 cUNOP->op_first = arg;
666 case INSN_OP_LAST: /* 91 */
670 cBINOP->op_last = arg;
673 case INSN_OP_OTHER: /* 92 */
677 cLOGOP->op_other = arg;
680 case INSN_OP_TRUE: /* 93 */
684 cCONDOP->op_true = arg;
687 case INSN_OP_FALSE: /* 94 */
691 cCONDOP->op_false = arg;
694 case INSN_OP_CHILDREN: /* 95 */
698 cLISTOP->op_children = arg;
701 case INSN_OP_PMREPLROOT: /* 96 */
705 cPMOP->op_pmreplroot = arg;
708 case INSN_OP_PMREPLROOTGV: /* 97 */
712 *(SV**)&cPMOP->op_pmreplroot = arg;
715 case INSN_OP_PMREPLSTART: /* 98 */
719 cPMOP->op_pmreplstart = arg;
722 case INSN_OP_PMNEXT: /* 99 */
726 *(OP**)&cPMOP->op_pmnext = arg;
729 case INSN_PREGCOMP: /* 100 */
732 BGET_pvcontents(arg);
733 BSET_pregcomp(PL_op, arg);
736 case INSN_OP_PMFLAGS: /* 101 */
740 cPMOP->op_pmflags = arg;
743 case INSN_OP_PMPERMFLAGS: /* 102 */
747 cPMOP->op_pmpermflags = arg;
750 case INSN_OP_SV: /* 103 */
757 case INSN_OP_GV: /* 104 */
761 *(SV**)&cGVOP->op_gv = arg;
764 case INSN_OP_PV: /* 105 */
767 BGET_pvcontents(arg);
771 case INSN_OP_PV_TR: /* 106 */
774 BGET_op_tr_array(arg);
778 case INSN_OP_REDOOP: /* 107 */
782 cLOOP->op_redoop = arg;
785 case INSN_OP_NEXTOP: /* 108 */
789 cLOOP->op_nextop = arg;
792 case INSN_OP_LASTOP: /* 109 */
796 cLOOP->op_lastop = arg;
799 case INSN_COP_LABEL: /* 110 */
802 BGET_pvcontents(arg);
803 cCOP->cop_label = arg;
806 case INSN_COP_STASH: /* 111 */
810 *(SV**)&cCOP->cop_stash = arg;
813 case INSN_COP_FILEGV: /* 112 */
817 *(SV**)&cCOP->cop_filegv = arg;
820 case INSN_COP_SEQ: /* 113 */
827 case INSN_COP_ARYBASE: /* 114 */
831 cCOP->cop_arybase = arg;
834 case INSN_COP_LINE: /* 115 */
838 cCOP->cop_line = arg;
841 case INSN_MAIN_START: /* 116 */
848 case INSN_MAIN_ROOT: /* 117 */
855 case INSN_CURPAD: /* 118 */
859 BSET_curpad(PL_curpad, arg);
863 croak("Illegal bytecode instruction %d\n", insn);