3 * Copyright (c) 1991-1999, Larry Wall
5 * You may distribute under the terms of either the GNU General Public
6 * License or the Artistic License, as specified in the README file.
15 * "Away now, Shadowfax! Run, greatheart, run as you have never run before!
16 * Now we are come to the lands where you were foaled, and every stone you
17 * know. Run now! Hope is in speed!" --Gandalf
21 #define CALLOP this->*PL_op
27 Perl_runops_standard(pTHX)
31 while ( PL_op = (CALLOP->op_ppaddr)(aTHX) ) ;
38 Perl_runops_debug(pTHX)
43 if (ckWARN_d(WARN_DEBUGGING))
44 Perl_warner(aTHX_ WARN_DEBUGGING, "NULL OP IN RUN");
50 if (PL_watchaddr != 0 && *PL_watchaddr != PL_watchok)
51 PerlIO_printf(Perl_debug_log, "WARNING: %lx changed from %lx to %lx\n",
52 (long)PL_watchaddr, (long)PL_watchok, (long)*PL_watchaddr);
54 DEBUG_t(debop(PL_op));
55 DEBUG_P(debprof(PL_op));
57 } while ( PL_op = (CALLOP->op_ppaddr)(aTHX) );
62 return runops_standard();
63 #endif /* DEBUGGING */
67 Perl_debop(pTHX_ OP *o)
72 Perl_deb(aTHX_ "%s", PL_op_name[o->op_type]);
75 PerlIO_printf(Perl_debug_log, "(%s)", SvPEEK(cSVOPo->op_sv));
81 gv_fullname3(sv, cGVOPo->op_gv, Nullch);
82 PerlIO_printf(Perl_debug_log, "(%s)", SvPV(sv, n_a));
86 PerlIO_printf(Perl_debug_log, "(NULL)");
91 PerlIO_printf(Perl_debug_log, "\n");
92 #endif /* DEBUGGING */
97 Perl_watch(pTHX_ char **addr)
103 PerlIO_printf(Perl_debug_log, "WATCHING, %lx is currently %lx\n",
104 (long)PL_watchaddr, (long)PL_watchok);
105 #endif /* DEBUGGING */
109 S_debprof(pTHX_ OP *o)
113 Newz(000, PL_profiledata, MAXO, U32);
114 ++PL_profiledata[o->op_type];
115 #endif /* DEBUGGING */
119 Perl_debprofdump(pTHX)
125 for (i = 0; i < MAXO; i++) {
126 if (PL_profiledata[i])
127 PerlIO_printf(Perl_debug_log,
128 "%5lu %s\n", (unsigned long)PL_profiledata[i],
131 #endif /* DEBUGGING */