Branch Coverage

mg.c
Criterion Covered Total %
branch 929 1412 65.8


line true false branch
107 57669372 0 if (SvREFCNT(sv) > 0) {
145 54566295 3 if ((mg = SvMAGIC(sv))) {
148 55299077 141570 if (vtbl) {
149 24324911 30974166 if (vtbl->svt_get && !(mg->mg_flags & MGf_GSKIP))
22028830 2296081 if (vtbl->svt_get && !(mg->mg_flags & MGf_GSKIP))
151 44592526 10706551 if (vtbl->svt_set)
153 14563319 40735758 if (vtbl->svt_clear)
156 874352 54566295 } while ((mg = mg->mg_moremagic));
157 10827989 43738306 if (!(SvFLAGS(sv) & (SVs_GMG|SVs_SMG)))
182 6460721 28777550 if (PL_localizing == 1 && sv == DEFSV) return 0;
6458459 2262 if (PL_localizing == 1 && sv == DEFSV) return 0;
6460706 15 if (PL_localizing == 1 && sv == DEFSV) return 0;
189 35247422 35238212 while (mg) {
193 35247422 0 if (!(mg->mg_flags & MGf_GSKIP) && vtbl && vtbl->svt_get) {
35238340 9082 if (!(mg->mg_flags & MGf_GSKIP) && vtbl && vtbl->svt_get) {
196 35238339 1 if (!saved && mg->mg_type != PERL_MAGIC_taint) {
34674408 563931 if (!saved && mg->mg_type != PERL_MAGIC_taint) {
205 5 35238296 if (!SvMAGIC(sv)) {
211 1148242 34090054 if (mg->mg_flags & MGf_GSKIP)
214 0 9082 else if (vtbl == &PL_vtbl_utf8) {
221 1 35247377 if (have_new) {
224 1 0 if (mg == head) {
232 35247378 0 if (!have_new && (newmg = SvMAGIC(sv)) != head) {
1 35247377 if (!have_new && (newmg = SvMAGIC(sv)) != head) {
240 34674369 563848 if (saved)
264 6517922 14661995 if (PL_localizing == 2 && sv == DEFSV) return 0;
6517922 0 if (PL_localizing == 2 && sv == DEFSV) return 0;
6497757 20165 if (PL_localizing == 2 && sv == DEFSV) return 0;
268 21160158 21159678 for (mg = SvMAGIC(sv); mg; mg = nextmg) {
271 388 21159770 if (mg->mg_flags & MGf_GSKIP) {
275 6497758 14662400 if (PL_localizing == 2
276 6 6497752 && PERL_MAGIC_TYPE_IS_VALUE_MAGIC(mg->mg_type))
278 21160141 11 if (vtbl && vtbl->svt_set)
21160120 21 if (vtbl && vtbl->svt_set)
307 0 0 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
309 0 0 if (vtbl && vtbl->svt_len) {
0 0 if (vtbl && vtbl->svt_len) {
319 0 0 (void)SvPV_const(sv, len);
330 61228 60131 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
332 61228 0 if (vtbl && vtbl->svt_len) {
1007 60221 if (vtbl && vtbl->svt_len) {
343 60131 0 switch(SvTYPE(sv)) {
374 1834228 1834199 for (mg = SvMAGIC(sv); mg; mg = nextmg) {
380 1834227 1 if (vtbl && vtbl->svt_clear)
1834220 7 if (vtbl && vtbl->svt_clear)
395 1 0 if (sv) {
0 0 if (sv) {
13570 0 if (sv) {
5 0 if (sv) {
7611 9 if (sv) {
0 0 if (sv) {
0 0 if (sv) {
4 0 if (sv) {
13792660 0 if (sv) {
10 0 if (sv) {
445022753 0 if (sv) {
400 1 0 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
0 0 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
13571 0 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
5 0 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
7611 0 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
0 0 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
0 0 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
6 0 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
15799538 861 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
7 6 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
436064313 413219566 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
401 0 1 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
0 0 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
1 13570 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
0 5 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
0 7611 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
0 0 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
0 0 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
2 4 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
2007739 13791799 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
7 0 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
3 4 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
404261126 31803187 if (mg->mg_type == type && (!flags || mg->mg_virtual == vtbl)) {
443 724 16201819 if (SvTYPE(sv) == SVt_PVLV && LvTYPE(sv) == 'y') {
9 715 if (SvTYPE(sv) == SVt_PVLV && LvTYPE(sv) == 'y') {
449 15547016 655527 if (SvTYPE(sv) >= SVt_PVMG && SvMAGIC(sv))
13792660 1754356 if (SvTYPE(sv) >= SVt_PVMG && SvMAGIC(sv))
470 4357907 4357646 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
472 1 4357906 if ((mg->mg_flags & MGf_COPY) && vtbl->svt_copy){
1 0 if ((mg->mg_flags & MGf_COPY) && vtbl->svt_copy){
477 4337517 20389 if (isUPPER(type) && type != PERL_MAGIC_uvar) {
478 4337517 0 sv_magic(nsv,
1198241 3139276 sv_magic(nsv,
1198241 0 sv_magic(nsv,
33380 3105896 sv_magic(nsv,
11136 22244 sv_magic(nsv,
514 6517922 2 if (nsv == DEFSV)
6497761 20163 if (nsv == DEFSV)
517 6497762 6497761 for (mg = SvMAGIC(sv); mg; mg = mg->mg_moremagic) {
519 12 6497750 if (PERL_MAGIC_TYPE_IS_VALUE_MAGIC(mg->mg_type))
522 0 6497750 if ((mg->mg_flags & MGf_LOCAL) && vtbl->svt_local)
0 0 if ((mg->mg_flags & MGf_LOCAL) && vtbl->svt_local)
532 6497756 5 if (SvTYPE(nsv) >= SVt_PVMG && SvMAGIC(nsv)) {
6497750 6 if (SvTYPE(nsv) >= SVt_PVMG && SvMAGIC(nsv)) {
534 6494589 3161 if (setmagic) {
536 6494587 2 SvSETMAGIC(nsv);
547 19916465 52733 if (vtbl && vtbl->svt_free)
7708 19908757 if (vtbl && vtbl->svt_free)
549 12665564 7303634 if (mg->mg_ptr && mg->mg_type != PERL_MAGIC_regex_global) {
12665564 0 if (mg->mg_ptr && mg->mg_type != PERL_MAGIC_regex_global) {
550 5085060 7580504 if (mg->mg_len > 0 || mg->mg_type == PERL_MAGIC_utf8)
25 5085035 if (mg->mg_len > 0 || mg->mg_type == PERL_MAGIC_utf8)
552 4729320 355715 else if (mg->mg_len == HEf_SVKEY)
555 1333681 18635517 if (mg->mg_flags & MGf_REFCOUNTED)
576 19969193 20336768 for (mg = SvMAGIC(sv); mg; mg = moremagic) {
599 9 6 for (prevmg = NULL, mg = SvMAGIC(sv); mg; prevmg = mg, mg = moremg) {
602 5 4 if (mg->mg_type == how) {
605 1 4 if (prevmg) {
629 127 10 if (PL_curpm) {
631 127 0 if (rx) {
632 62 65 if (mg->mg_obj) { /* @+ */
639 65 0 while ( paren >= 0
640 0 65 && (RX_OFFS(rx)[paren].start == -1
641 0 65 || RX_OFFS(rx)[paren].end == -1) )
660 66760 0 if (PL_curpm) {
662 66760 0 if (rx) {
666 66760 0 if (paren < 0)
668 66760 0 if (paren <= (I32)RX_NPARENS(rx) &&
66632 128 if (paren <= (I32)RX_NPARENS(rx) &&
669 66632 0 (s = RX_OFFS(rx)[paren].start) != -1 &&
673 22212 44420 if (mg->mg_obj) /* @+ */
678 4222 62410 if (RX_MATCH_UTF8(rx)) {
680 4222 0 if (b)
723 216 13 if (!(CopHINTS_get(c) & (HINT_LEXICAL_IO_IN|HINT_LEXICAL_IO_OUT)))
728 13 0 if ((CopHINTS_get(c) & HINT_LEXICAL_IO_IN)) {
734 13 0 if ((CopHINTS_get(c) & HINT_LEXICAL_IO_OUT)) {
761 365 797 if (SvOK(PL_bodytarget)) sv_copypv(sv, PL_bodytarget);
365 0 if (SvOK(PL_bodytarget)) sv_copypv(sv, PL_bodytarget);
0 365 if (SvOK(PL_bodytarget)) sv_copypv(sv, PL_bodytarget);
763 0 1162 if (SvTAINTED(PL_bodytarget))
0 0 if (SvTAINTED(PL_bodytarget))
764 0 0 SvTAINTED_on(sv);
767 261741 14 if (nextchar == '\0') {
770 14 0 else if (strEQ(remaining, "HILD_ERROR_NATIVE")) {
779 35779 7461 if (nextchar == '\0') {
818 74 35705 sv_setpv(sv, errno ? Strerror(errno) : "");
822 35779 0 SvRTRIM(sv);
74 35705 SvRTRIM(sv);
0 74 SvRTRIM(sv);
825 7461 0 else if (strEQ(remaining, "NCODING"))
832 7 0 if (strEQ(remaining, "LOBAL_PHASE")) {
844 0 0 if (strEQ(remaining, "AST_FH")) {
845 0 0 if (PL_last_in_gv) {
847 0 0 SV_CHECK_THINKFIRST_COW_DROP(sv);
848 0 0 prepare_SV_for_RV(sv);
0 0 prepare_SV_for_RV(sv);
0 0 prepare_SV_for_RV(sv);
0 0 prepare_SV_for_RV(sv);
0 0 prepare_SV_for_RV(sv);
0 0 prepare_SV_for_RV(sv);
849 0 0 SvOK_off(sv);
858 562721 229 if (nextchar == '\0') {
860 1606 561115 SvTAINTED_off(sv);
862 229 0 else if (strEQ(remaining, "PEN")) {
229 0 else if (strEQ(remaining, "PEN")) {
229 0 else if (strEQ(remaining, "PEN")) {
229 0 else if (strEQ(remaining, "PEN")) {
867 2775 179 if (nextchar == '\0') { /* ^P */
869 24 155 } else if (strEQ(remaining, "REMATCH")) { /* $^PREMATCH */
873 24 0 } else if (strEQ(remaining, "OSTMATCH")) { /* $^POSTMATCH */
879 224 0 if (nextchar == '\0') {
880 184 40 if (PL_parser && PL_parser->lex_state != LEX_NOTPARSING)
184 0 if (PL_parser && PL_parser->lex_state != LEX_NOTPARSING)
881 0 184 SvOK_off(sv);
882 26 14 else if (PL_in_eval)
889 365 16841 if (nextchar == '\0') {
896 16841 0 else if (strEQ(remaining, "AINT"))
897 131 16710 sv_setiv(sv, TAINTING_get
130 1 sv_setiv(sv, TAINTING_get
130 0 sv_setiv(sv, TAINTING_get
902 169 134 if (strEQ(remaining, "NICODE"))
904 128 6 else if (strEQ(remaining, "TF8LOCALE"))
906 6 0 else if (strEQ(remaining, "TF8CACHE"))
910 4231342 257798 if (nextchar == '\0')
911 4124562 106780 sv_setiv(sv, (IV)((PL_dowarn & G_WARN_ON) ? TRUE : FALSE));
912 257798 0 else if (strEQ(remaining, "ARNING_BITS")) {
913 319 257479 if (PL_compiling.cop_warnings == pWARN_NONE) {
916 124301 133178 else if (PL_compiling.cop_warnings == pWARN_STD) {
920 108920 24258 else if (PL_compiling.cop_warnings == pWARN_ALL) {
924 108920 0 SV ** const bits_all = bits ? hv_fetchs(bits, "all", FALSE) : NULL;
925 108920 0 if (bits_all)
937 0 26 if (strEQ(remaining, "ATCH")) {
950 23756895 1078 if (PL_curpm && (rx = PM_GETRE(PL_curpm))) {
23756895 0 if (PL_curpm && (rx = PM_GETRE(PL_curpm))) {
957 5275 0 if (PL_curpm && (rx = PM_GETRE(PL_curpm))) {
5275 0 if (PL_curpm && (rx = PM_GETRE(PL_curpm))) {
959 5274 1 if (paren)
965 286 0 if (PL_curpm && (rx = PM_GETRE(PL_curpm))) {
286 0 if (PL_curpm && (rx = PM_GETRE(PL_curpm))) {
967 285 1 if (paren)
979 266382 377546 if (GvIO(PL_last_in_gv)) {
266360 22 if (GvIO(PL_last_in_gv)) {
266360 0 if (GvIO(PL_last_in_gv)) {
266359 1 if (GvIO(PL_last_in_gv)) {
994 9 0 if (GvIOp(PL_defoutgv))
996 3 6 if (s)
999 6 0 sv_setpv(sv,GvENAME(PL_defoutgv));
1004 26 0 if (GvIOp(PL_defoutgv))
1006 9 17 if (!s)
1007 9 0 s = GvENAME(PL_defoutgv);
1011 12 0 if (GvIO(PL_defoutgv))
12 0 if (GvIO(PL_defoutgv))
12 0 if (GvIO(PL_defoutgv))
12 0 if (GvIO(PL_defoutgv))
1015 11 0 if (GvIO(PL_defoutgv))
11 0 if (GvIO(PL_defoutgv))
11 0 if (GvIO(PL_defoutgv))
11 0 if (GvIO(PL_defoutgv))
1019 8 0 if (GvIO(PL_defoutgv))
8 0 if (GvIO(PL_defoutgv))
8 0 if (GvIO(PL_defoutgv))
8 0 if (GvIO(PL_defoutgv))
1030 1142 0 if (GvIO(PL_defoutgv))
1142 0 if (GvIO(PL_defoutgv))
1142 0 if (GvIO(PL_defoutgv))
1142 0 if (GvIO(PL_defoutgv))
1034 1307 537521 if (PL_ors_sv)
1042 236 186350 if (isGV(mg->mg_obj) || SvIV(mg->mg_obj) != pid) {
236 0 if (isGV(mg->mg_obj) || SvIV(mg->mg_obj) != pid) {
235 1 if (isGV(mg->mg_obj) || SvIV(mg->mg_obj) != pid) {
1046 31 186554 SvTAINTED_off(sv);
1065 956593 244295 if (! errno) {
1087 0 244295 if (SvOK(sv) /* It could be that Strerror returned invalid */
0 0 if (SvOK(sv) /* It could be that Strerror returned invalid */
0 0 if (SvOK(sv) /* It could be that Strerror returned invalid */
1088 0 244295 && ! is_ascii_string((U8*) SvPVX_const(sv), SvCUR(sv))
1089 0 0 && is_utf8_string((U8*) SvPVX_const(sv), SvCUR(sv)))
1097 1200888 0 SvRTRIM(sv);
244295 956593 SvRTRIM(sv);
0 244295 SvRTRIM(sv);
1116 0 79 Newx(gary, num_groups, Groups_t);
1118 158 79 for (i = 0; i < num_groups; i++)
1138 40344 0 if (uf && uf->uf_val)
40341 3 if (uf && uf->uf_val)
1145 0 182976 {
1148 176981 5995 const char * const key = MgPV_const(mg,klen);
176981 0 const char * const key = MgPV_const(mg,klen);
1154 1693 181283 if (SvOK(sv)) {
1693 0 if (SvOK(sv)) {
0 1693 if (SvOK(sv)) {
1157 181283 0 (void)SvPV_force_nomg_nolen(sv);
1159 0 181283 if (SvUTF8(sv)) {
1181 1 182975 if (TAINTING_get) {
1210 1 0 if (s && klen == 4 && strEQ(key,"PATH")) {
0 1 if (s && klen == 4 && strEQ(key,"PATH")) {
0 0 if (s && klen == 4 && strEQ(key,"PATH")) {
1213 0 0 while (s < strend) {
1225 0 0 if (i >= (I32)sizeof tmpbuf /* too long -- assume the worst */
1229 0 0 || *tmpbuf != '/' /* no starting slash -- assume relative path */
1231 0 0 || (PerlLIO_stat(tmpbuf, &st) == 0 && (st.st_mode & 2)) ) {
0 0 || (PerlLIO_stat(tmpbuf, &st) == 0 && (st.st_mode & 2)) ) {
1248 31790 149 my_setenv(MgPV_nolen_const(mg),NULL);
31790 0 my_setenv(MgPV_nolen_const(mg),NULL);
1261 5076 0 if (PL_localizing) {
1265 184847 5076 while ((entry = hv_iternext(MUTABLE_HV(sv)))) {
1267 184847 0 my_setenv(hv_iterkey(entry, &keylen),
1295 2259 0 const sigset_t * const ossetp = (const sigset_t *) SvPV_nolen_const( save_sv );
1308 87382 75288 if (!i) {
1310 87280 102 const char * sig = MgPV_const(mg, siglen);
87280 0 const char * sig = MgPV_const(mg, siglen);
1314 1301 161369 if (i > 0) {
1315 1198 103 if(PL_psig_ptr[i])
1328 5 98 if(sigstate == (Sighandler_t) SIG_IGN)
1371 77 0 if (
1376 77 0 sig == SIGBUS ||
1379 0 77 sig == SIGSEGV ||
1390 77 0 if (!PL_psig_pend) return;
1399 0 77 if (++PL_sig_pending >= SIG_PENDING_DIE_COUNT)
1440 4386 62 for (sig = 1; sig < SIG_SIZE; sig++) {
1441 77 4309 if (PL_psig_pend[sig]) {
1458 75 2 if (!was_blocked) {
1462 75 0 SAVEDESTRUCTOR_X(unblock_sigmask, SvPV_nolen(save_sv));
1472 61 1 if (!was_blocked)
1497 1915640 2138 const char *s = MgPV_const(mg,len);
1915640 0 const char *s = MgPV_const(mg,len);
1501 1915505 2273 if (*s == '_') {
1502 1333131 582374 if (memEQs(s, len, "__DIE__"))
1 1333130 if (memEQs(s, len, "__DIE__"))
1504 582372 3 else if (memEQs(s, len, "__WARN__")
582372 0 else if (memEQs(s, len, "__WARN__")
1505 249100 333272 && (sv ? 1 : PL_warnhook != PERL_WARNHOOK_FATAL)) {
0 249100 && (sv ? 1 : PL_warnhook != PERL_WARNHOOK_FATAL)) {
1512 3 0 } else if (sv) {
1518 1915502 0 if (svp && *svp) {
305733 1609769 if (svp && *svp) {
1519 305733 0 if (*svp != PERL_WARNHOOK_FATAL)
1526 1326 947 if (!i) {
1530 14 2259 if (i <= 0) {
1531 14 0 if (sv) {
1548 0 2259 PERL_ASYNC_CHECK();
1559 2252 7 if (sv) {
1569 480 1772 if (!PL_psig_name[i]) {
1579 448872 1468889 if (sv && (isGV_with_GP(sv) || SvROK(sv))) {
0 448872 if (sv && (isGV_with_GP(sv) || SvROK(sv))) {
0 0 if (sv && (isGV_with_GP(sv) || SvROK(sv))) {
307153 141719 if (sv && (isGV_with_GP(sv) || SvROK(sv))) {
1580 1118 306035 if (i) {
1586 141719 1468889 if (sv && SvOK(sv)) {
140916 803 if (sv && SvOK(sv)) {
140916 0 if (sv && SvOK(sv)) {
0 140916 if (sv && SvOK(sv)) {
1587 0 803 s = SvPV_force(sv, len);
1591 803 1609805 if (sv && memEQs(s, len,"IGNORE")) {
351 452 if (sv && memEQs(s, len,"IGNORE")) {
350 1 if (sv && memEQs(s, len,"IGNORE")) {
1592 350 0 if (i) {
1601 453 1609805 else if (!sv || memEQs(s, len,"DEFAULT") || !len) {
27 426 else if (!sv || memEQs(s, len,"DEFAULT") || !len) {
1 26 else if (!sv || memEQs(s, len,"DEFAULT") || !len) {
405 22 else if (!sv || memEQs(s, len,"DEFAULT") || !len) {
1602 770 1609466 if (i) {
1617 16 6 if (!strchr(s,':') && !strchr(s,'\''))
16 0 if (!strchr(s,':') && !strchr(s,'\''))
1620 21 1 if (i)
1628 2259 1915502 if(i)
1644 418801 42584 if (PL_delaymagic & DM_ARRAY_ISA && mg->mg_type == PERL_MAGIC_isaelem)
224468 194333 if (PL_delaymagic & DM_ARRAY_ISA && mg->mg_type == PERL_MAGIC_isaelem)
1660 267097 0 if(PL_phase == PERL_PHASE_DESTRUCT) return 0;
1662 8 267089 if (sv)
1665 41 267056 if (SvTYPE(mg->mg_obj) != SVt_PVGV && SvSMAGICAL(mg->mg_obj))
4 37 if (SvTYPE(mg->mg_obj) != SVt_PVGV && SvSMAGICAL(mg->mg_obj))
1670 37 267060 if (SvTYPE(mg->mg_obj) == SVt_PVAV) { /* multiple stashes */
1673 115 37 while (items--) {
1675 81 34 if (stash && HvENAME(stash)) mro_isa_changed_in(stash);
81 0 if (stash && HvENAME(stash)) mro_isa_changed_in(stash);
81 0 if (stash && HvENAME(stash)) mro_isa_changed_in(stash);
81 0 if (stash && HvENAME(stash)) mro_isa_changed_in(stash);
0 81 if (stash && HvENAME(stash)) mro_isa_changed_in(stash);
0 81 if (stash && HvENAME(stash)) mro_isa_changed_in(stash);
81 0 if (stash && HvENAME(stash)) mro_isa_changed_in(stash);
81 0 if (stash && HvENAME(stash)) mro_isa_changed_in(stash);
1687 267058 2 if (stash && HvENAME_get(stash))
267058 0 if (stash && HvENAME_get(stash))
267058 0 if (stash && HvENAME_get(stash))
267058 0 if (stash && HvENAME_get(stash))
0 267058 if (stash && HvENAME_get(stash))
1 267057 if (stash && HvENAME_get(stash))
267057 0 if (stash && HvENAME_get(stash))
267058 0 if (stash && HvENAME_get(stash))
1702 86 0 if (hv) {
1704 0 86 if (! SvTIED_mg((const SV *)hv, PERL_MAGIC_tied))
0 0 if (! SvTIED_mg((const SV *)hv, PERL_MAGIC_tied))
1705 18 68 i = HvUSEDKEYS(hv);
1707 0 0 while (hv_iternext(hv))
1721 7 0 if (LvTARG(sv)) {
1722 6 1 hv_ksplit(MUTABLE_HV(LvTARG(sv)), SvIV(sv));
1756 0 2211605 {
1765 8 2211597 if (flags & G_WRITING_TO_STDERR) {
1773 394 2211211 PUSHSTACKi(PERLSI_MAGIC);
1774 0 2211605 PUSHMARK(SP);
1777 2211604 1 PUSHs(SvTIED_obj(sv, mg));
1778 0 2211605 if (flags & G_UNDEF_FILL) {
1779 0 0 while (argc--) {
1782 2208182 3423 } else if (argc > 0) {
1787 2208182 5153 SV *const sv = va_arg(args, SV *);
1789 5153 2208182 } while (--argc);
1794 5875 2205730 if (flags & G_DISCARD) {
1798 2205682 0 if (call_sv(meth, G_SCALAR|G_METHOD_NAMED))
1801 0 2211535 POPSTACK;
1802 7 2211528 if (flags & G_WRITING_TO_STDERR)
1803 0 7 FREETMPS;
1819 1195408 5225 if (mg->mg_ptr) {
1820 6 1195402 if (mg->mg_len >= 0) {
1823 1195402 0 else if (mg->mg_len == HEf_SVKEY)
1826 3227 1998 else if (mg->mg_type == PERL_MAGIC_tiedelem) {
1830 1998 1198635 if (!arg1) {
1845 1194169 0 if (ret)
1855 1148248 729 if (mg->mg_type == PERL_MAGIC_tiedelem)
1857 1143008 5969 magic_methpack(sv,mg,SV_CONST(FETCH));
1880 0 5552 if (TAINTING_get && (tmg = mg_find(sv, PERL_MAGIC_taint))
0 0 if (TAINTING_get && (tmg = mg_find(sv, PERL_MAGIC_taint))
1881 0 0 && (tmg->mg_len & 1))
1884 0 0 SvTAINTED_on(val);
1889 5232 320 magic_methcall1(sv, mg, SV_CONST(STORE), G_DISCARD, 2, val);
1898 803 2 if (mg->mg_type == PERL_MAGIC_tiedscalar) return 0;
1899 745 58 return magic_methpack(sv,mg,SV_CONST(DELETE));
1912 835 35 retsv = magic_methcall1(sv, mg, SV_CONST(FETCHSIZE), 0, 1, NULL);
1913 866 0 if (retsv) {
1914 866 0 retval = SvIV(retsv)-1;
1915 1 865 if (retval < -1)
1928 119 37 Perl_magic_methcall(aTHX_ sv, mg, SV_CONST(CLEAR), G_DISCARD, 0);
1940 1622 0 ret = SvOK(key) ? Perl_magic_methcall(aTHX_ sv, mg, SV_CONST(NEXTKEY), 0, 1, key)
0 1622 ret = SvOK(key) ? Perl_magic_methcall(aTHX_ sv, mg, SV_CONST(NEXTKEY), 0, 1, key)
1008267 714 ret = SvOK(key) ? Perl_magic_methcall(aTHX_ sv, mg, SV_CONST(NEXTKEY), 0, 1, key)
1941 1622 1008981 : Perl_magic_methcall(aTHX_ sv, mg, SV_CONST(FIRSTKEY), 0, 0);
904 718 : Perl_magic_methcall(aTHX_ sv, mg, SV_CONST(FIRSTKEY), 0, 0);
1942 1010601 0 if (ret)
1952 44377 54 return magic_methpack(sv,mg,SV_CONST(EXISTS));
1960 20 0 SV * const tied = SvTIED_obj(MUTABLE_SV(hv), mg);
1965 5 15 if (!gv_fetchmethod_autoload(pkg, "SCALAR", FALSE)) {
1967 2 3 if (HvEITER_get(hv))
1 1 if (HvEITER_get(hv))
1974 2 2 return SvOK(key) ? &PL_sv_yes : &PL_sv_no;
2 0 return SvOK(key) ? &PL_sv_yes : &PL_sv_no;
2 0 return SvOK(key) ? &PL_sv_yes : &PL_sv_no;
1978 10 5 retval = Perl_magic_methcall(aTHX_ MUTABLE_SV(hv), mg, SV_CONST(SCALAR), 0, 0);
1979 0 15 if (!retval)
1993 0 65 if (UNLIKELY(mg->mg_len != HEf_SVKEY)) {
2002 65 0 if (svp && SvIOKp(*svp)) {
65 0 if (svp && SvIOKp(*svp)) {
2004 65 0 if (o) {
2009 65 0 if (SvTRUE(sv))
0 65 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
0 65 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
65 0 if (SvTRUE(sv))
65 0 if (SvTRUE(sv))
53 12 if (SvTRUE(sv))
47 6 if (SvTRUE(sv))
0 47 if (SvTRUE(sv))
59 6 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
0 0 if (SvTRUE(sv))
2029 169 8 if (obj) {
2030 169 0 sv_setiv(sv, AvFILL(obj));
2045 25095 10 if (obj) {
2046 24610 485 av_fill(obj, SvIV(sv));
2066 5 7384 if (mg->mg_ptr)
2082 7620 0 if (PL_in_clean_all)
2087 7611 9 if (mg) {
2108 4650 8 if (found && found->mg_len != -1) {
4591 59 if (found && found->mg_len != -1) {
2110 1340 3251 if (found->mg_flags & MGf_BYTES && DO_UTF8(lsv))
1 1339 if (found->mg_flags & MGf_BYTES && DO_UTF8(lsv))
1 0 if (found->mg_flags & MGf_BYTES && DO_UTF8(lsv))
2134 31772 5550 if (!found) {
2135 149 31623 if (!SvOK(sv))
149 0 if (!SvOK(sv))
0 149 if (!SvOK(sv))
2139 23 5527 else if (!SvOK(sv)) {
23 0 else if (!SvOK(sv)) {
23 0 else if (!SvOK(sv)) {
2143 37139 11 s = SvPV_const(lsv, len);
2145 37149 1 pos = SvIV(sv);
2147 523 36627 if (DO_UTF8(lsv)) {
523 0 if (DO_UTF8(lsv)) {
2148 522 1 ulen = sv_or_pv_len_utf8(lsv, s, len);
3 519 ulen = sv_or_pv_len_utf8(lsv, s, len);
3 0 ulen = sv_or_pv_len_utf8(lsv, s, len);
0 3 ulen = sv_or_pv_len_utf8(lsv, s, len);
2149 523 0 if (ulen)
2153 0 37150 if (pos < 0) {
2155 0 0 if (pos < 0)
2158 2 37148 else if (pos > (SSize_t)len)
2172 32522 10 const char * const tmps = SvPV_const(lsv,len);
2181 13058 19474 if (!translate_substr_offsets(
59 32473 if (!translate_substr_offsets(
1334 31198 if (!translate_substr_offsets(
1334 0 if (!translate_substr_offsets(
3 1331 if (!translate_substr_offsets(
3 0 if (!translate_substr_offsets(
2 1 if (!translate_substr_offsets(
1 32531 if (!translate_substr_offsets(
2191 1334 31197 if (SvUTF8(lsv))
2194 1334 31197 if (SvUTF8(lsv))
2201 0 2060 {
2204 2054 6 const char * const tmps = SvPV_const(sv, len);
2215 3 2057 if (SvROK(lsv))
2219 1537 523 SvPV_force_nomg(lsv,lsv_len);
2220 3 2057 if (SvUTF8(lsv)) lsv_len = sv_len_utf8_nomg(lsv);
2221 1971 89 if (!translate_substr_offsets(
5 2055 if (!translate_substr_offsets(
0 2060 if (!translate_substr_offsets(
2228 3 2057 if (DO_UTF8(sv)) {
3 0 if (DO_UTF8(sv)) {
2232 3 0 newtarglen = sv_or_pv_len_utf8(sv, tmps, len);
1 2 newtarglen = sv_or_pv_len_utf8(sv, tmps, len);
1 0 newtarglen = sv_or_pv_len_utf8(sv, tmps, len);
1 0 newtarglen = sv_or_pv_len_utf8(sv, tmps, len);
2235 2 2055 else if (SvUTF8(lsv)) {
2247 89 1971 if (!neglen) LvTARGLEN(sv) = newtarglen;
2248 5 2055 if (negoff) LvTARGOFF(sv) += newtarglen - oldtarglen;
2264 563928 4 TAINT_IF((PL_localizing != 1) && (mg->mg_len & 1));
563283 645 TAINT_IF((PL_localizing != 1) && (mg->mg_len & 1));
2277 2701 821 if (TAINT_get)
2312 5 60175 if (!mg) mg = mg_find(sv, PERL_MAGIC_defelem);
2314 46464 13716 if (LvTARGLEN(sv)) {
2315 32938 13526 if (mg->mg_obj) {
2318 1 32937 if (he)
2321 13522 4 else if (LvSTARGOFF(sv) >= 0) {
2323 0 13522 if (LvSTARGOFF(sv) <= AvFILL(av))
13304 218 if (LvSTARGOFF(sv) <= AvFILL(av))
2326 1 46463 if (targ && (targ != &PL_sv_undef)) {
1 0 if (targ && (targ != &PL_sv_undef)) {
2355 13565 41 if (LvTARGLEN(sv))
2357 13602 0 if (LvTARG(sv)) {
2359 1 13601 SvSETMAGIC(LvTARG(sv));
2373 13570 12 if (!LvTARGLEN(sv) || !(mg = mg_find(sv, PERL_MAGIC_defelem)))
13570 0 if (!LvTARGLEN(sv) || !(mg = mg_find(sv, PERL_MAGIC_defelem)))
2375 261 13309 if (mg->mg_obj) {
2378 261 0 if (he)
2380 261 0 if (!value || value == &PL_sv_undef)
0 261 if (!value || value == &PL_sv_undef)
2383 4 13305 else if (LvSTARGOFF(sv) < 0)
2387 13299 6 if ((I32)LvTARGLEN(sv) < 0 && LvSTARGOFF(sv) > AvFILL(av))
0 13299 if ((I32)LvTARGLEN(sv) < 0 && LvSTARGOFF(sv) > AvFILL(av))
0 13299 if ((I32)LvTARGLEN(sv) < 0 && LvSTARGOFF(sv) > AvFILL(av))
2391 13305 0 if (!svp || !(value = *svp))
0 13305 if (!svp || !(value = *svp))
2395 13566 0 SvREFCNT_inc_simple_void(value);
2429 20053 0 if (uf && uf->uf_set)
20051 2 if (uf && uf->uf_set)
2441 126 0 if (type == PERL_MAGIC_qr) {
2442 0 126 } else if (type == PERL_MAGIC_bm) {
2463 0 0 if (mg->mg_ptr) {
2501 0 0 if (strEQ(remaining, "ATCH"))
2519 147146 1638 if (PL_curpm && (rx = PM_GETRE(PL_curpm))) {
147146 0 if (PL_curpm && (rx = PM_GETRE(PL_curpm))) {
2527 4 1634 if (!PL_localizing) {
2533 799 798 if (SvOK(sv)) sv_copypv(PL_bodytarget, sv);
799 0 if (SvOK(sv)) sv_copypv(PL_bodytarget, sv);
0 799 if (SvOK(sv)) sv_copypv(PL_bodytarget, sv);
2534 2 797 else SvOK_off(PL_bodytarget);
2536 798 799 if (SvPOK(PL_bodytarget)) {
2538 10 798 while ( ((s = strchr(s, '\n'))) ) {
2544 0 1597 if (TAINTING_get) {
2545 0 0 if ((tmg = mg_find(sv,PERL_MAGIC_taint)) && tmg->mg_len & 1)
0 0 if ((tmg = mg_find(sv,PERL_MAGIC_taint)) && tmg->mg_len & 1)
2546 0 0 SvTAINTED_on(PL_bodytarget);
2548 0 0 SvTAINTED_off(PL_bodytarget);
2552 3 1 PL_minus_c = cBOOL(SvIV(sv));
2562 194 0 PL_debug = (SvIV(sv)) | DEBUG_TOP_FLAG;
2566 70986 14940 if (*(mg->mg_ptr+1) == '\0') {
2577 18 70968 SETERRNO(SvIV(sv), 4);
2582 14940 0 else if (strEQ(mg->mg_ptr+1, "NCODING")) {
2584 9175 5765 if (SvOK(sv) || SvGMAGICAL(sv)) {
9175 0 if (SvOK(sv) || SvGMAGICAL(sv)) {
9175 0 if (SvOK(sv) || SvGMAGICAL(sv)) {
0 9175 if (SvOK(sv) || SvGMAGICAL(sv)) {
2593 432 215 PL_maxsysfd = SvIV(sv);
2596 1162703 2335 PL_hints = SvIV(sv);
2600 12 11 PL_inplace = SvOK(sv) ? savesvpv(sv) : NULL;
12 0 PL_inplace = SvOK(sv) ? savesvpv(sv) : NULL;
0 12 PL_inplace = SvOK(sv) ? savesvpv(sv) : NULL;
2603 0 0 if (PL_curpm && (rx = PM_GETRE(PL_curpm))
0 0 if (PL_curpm && (rx = PM_GETRE(PL_curpm))
2604 0 0 && (paren = RX_LASTCLOSEPAREN(rx))) goto setparen_got_rx;
2607 107 216 if (*(mg->mg_ptr+1) == '\0') {
2610 2 105 if (SvOK(sv)) {
2 0 if (SvOK(sv)) {
0 2 if (SvOK(sv)) {
2611 1 104 TAINT_PROPER("assigning to $^O");
2615 216 0 else if (strEQ(mg->mg_ptr, "\017PEN")) {
2617 216 0 const char *const start = SvPV(sv, len);
2629 216 0 : newSVpvs_flags("", SvUTF8(sv));
2633 216 0 tmp = newSVpvn_flags(start, out ? (STRLEN)(out - start) : len,
2640 2381 0 if (*remaining == '\0') { /* ^P */
2641 2369 12 PL_perldb = SvIV(sv);
2642 2365 16 if (PL_perldb && !PL_DBsingle)
2339 26 if (PL_perldb && !PL_DBsingle)
2645 0 0 } else if (strEQ(remaining, "REMATCH")) { /* $^PREMATCH */
2647 0 0 } else if (strEQ(remaining, "OSTMATCH")) { /* $^POSTMATCH */
2655 0 0 PL_basetime = (Time_t)SvIV(sv);
2659 18 0 if (strEQ(mg->mg_ptr+1, "TF8CACHE")) {
2664 8231886 191045 if (*(mg->mg_ptr+1) == '\0') {
2665 8230117 1769 if ( ! (PL_dowarn & G_WARN_ALL_MASK)) {
2666 4125803 4104314 i = SvIV(sv);
2671 191045 0 else if (strEQ(mg->mg_ptr+1, "ARNING_BITS")) {
2672 190930 115 if ( ! (PL_dowarn & G_WARN_ALL_MASK)) {
2673 4 190926 if (!SvPOK(sv)) {
2681 190926 0 const char * const ptr = SvPV_const(sv, len) ;
2682 2871825 190926 for (i = 0 ; i < len ; ++i) {
2686 2741 188185 if (!accumulate) {
2687 103 2638 if (!specialWARN(PL_compiling.cop_warnings))
50 53 if (!specialWARN(PL_compiling.cop_warnings))
2692 188185 0 else if (isWARN_on(
111377 76808 else if (isWARN_on(
2695 111294 83 && !any_fatals)
2697 28 111266 if (!specialWARN(PL_compiling.cop_warnings))
18 10 if (!specialWARN(PL_compiling.cop_warnings))
2704 76891 0 const char *const p = SvPV_const(sv, len);
2710 62836 14055 if (isWARN_on(PL_compiling.cop_warnings, WARN_ONCE))
2719 755280 10606 if (PL_localizing) {
2720 377640 377640 if (PL_localizing == 1)
2723 0 10606 else if (SvOK(sv) && GvIO(PL_last_in_gv))
0 0 else if (SvOK(sv) && GvIO(PL_last_in_gv))
0 0 else if (SvOK(sv) && GvIO(PL_last_in_gv))
3424 7182 else if (SvOK(sv) && GvIO(PL_last_in_gv))
3423 1 else if (SvOK(sv) && GvIO(PL_last_in_gv))
3423 0 else if (SvOK(sv) && GvIO(PL_last_in_gv))
3423 0 else if (SvOK(sv) && GvIO(PL_last_in_gv))
2724 3423 0 IoLINES(GvIOp(PL_last_in_gv)) = SvIV(sv);
2737 15 4 IoPAGE_LEN(GvIOp(PL_defoutgv)) = (SvIV(sv));
2740 6 0 IoLINES_LEFT(GvIOp(PL_defoutgv)) = (SvIV(sv));
2741 0 6 if (IoLINES_LEFT(GvIOp(PL_defoutgv)) < 0L)
2745 1 0 IoPAGE(GvIOp(PL_defoutgv)) = (SvIV(sv));
2749 12999 0 IO * const io = GvIO(PL_defoutgv);
12999 0 IO * const io = GvIO(PL_defoutgv);
12999 0 IO * const io = GvIO(PL_defoutgv);
2750 12999 0 if(!io)
2752 12850 149 if ((SvIV(sv)) == 0)
617 12382 if ((SvIV(sv)) == 0)
2755 10036 2346 if (!(IoFLAGS(io) & IOf_FLUSH)) {
2757 9879 157 if (ofp)
2770 1586832 22140 if (SvOK(sv)) {
1586832 0 if (SvOK(sv)) {
0 1586832 if (SvOK(sv)) {
2778 1 0 if (SvIV(sv) != 0)
1 0 if (SvIV(sv) != 0)
2795 17827 16258 STATUS_UNIX_EXIT_SET(SvIV(sv));
34082 3 STATUS_UNIX_EXIT_SET(SvIV(sv));
2804 15281 2387645 SETERRNO(SvIOK(sv) ? SvIVX(sv) : SvOK(sv) ? sv_2iv(sv) : 0,
1193212 1194433 SETERRNO(SvIOK(sv) ? SvIVX(sv) : SvOK(sv) ? sv_2iv(sv) : 0,
1193212 0 SETERRNO(SvIOK(sv) ? SvIVX(sv) : SvOK(sv) ? sv_2iv(sv) : 0,
0 1193212 SETERRNO(SvIOK(sv) ? SvIVX(sv) : SvOK(sv) ? sv_2iv(sv) : 0,
2810 0 0 const Uid_t new_uid = SvUID(sv);
2812 0 0 if (PL_delaymagic) {
2842 0 4 const Uid_t new_euid = SvUID(sv);
2844 0 4 if (PL_delaymagic) {
2869 0 0 const Gid_t new_gid = SvGID(sv);
2871 0 0 if (PL_delaymagic) {
2899 0 0 const char *p = SvPV_const(sv, len);
2904 0 0 if (maxgrp < 0)
2910 0 0 while (isSPACE(*p))
2913 0 0 for (i = 0; i < maxgrp; ++i) {
2914 0 0 while (*p && !isSPACE(*p))
0 0 while (*p && !isSPACE(*p))
2916 0 0 while (isSPACE(*p))
2918 0 0 if (!*p)
2920 0 0 if(!gary)
2921 0 0 Newx(gary, i + 1, Groups_t);
2923 0 0 Renew(gary, i + 1, Groups_t);
2926 0 0 if (i)
2934 0 0 if (PL_delaymagic) {
2958 30 0 PL_chopset = SvPV_force(sv,len);
2963 1 0 if (isGV(mg->mg_obj)) {
2964 0 1 if (mg->mg_flags & MGf_REFCOUNTED) /* probably never true */
3004 92 0 if (PL_origalen > 1) {
3006 90 2 s = SvPV_force(sv,len);
3007 0 92 if (len >= (STRLEN)PL_origalen-1) {
3030 375 92 for (i = 1; i < PL_origargc; i++)
3034 0 92 if (prctl(PR_SET_NAME, (unsigned long)s, 0, 0, 0) != 0) {
3054 2 0 sigpv = SvPV_const(sigsv, siglen);
3074 6045005 87292 for (sigv = (char* const*)PL_sig_name; *sigv; sigv++)
3075 12659 6032346 if (strlen(*sigv) == len && memEQ(sig,*sigv, len))
1474 11185 if (strlen(*sigv) == len && memEQ(sig,*sigv, len))
3078 3 87289 if (memEQs(sig, len, "CHLD"))
3 0 if (memEQs(sig, len, "CHLD"))
3082 1 87291 if (memEQs(sig, len, "CLD"))
1 0 if (memEQs(sig, len, "CLD"))
3112 0 91 if (!PL_psig_ptr[sig]) {
3113 0 0 PerlIO_printf(Perl_error_log, "Signal SIG%s received, but no signal handler set.\n",
0 0 PerlIO_printf(Perl_error_log, "Signal SIG%s received, but no signal handler set.\n",
0 0 PerlIO_printf(Perl_error_log, "Signal SIG%s received, but no signal handler set.\n",
0 0 PerlIO_printf(Perl_error_log, "Signal SIG%s received, but no signal handler set.\n",
3118 0 91 if (PL_signals & PERL_SIGNALS_UNSAFE_FLAG) {
3121 0 0 if (PL_savestack_ix + 15 <= PL_savestack_max) {
3128 75 16 if (!SvROK(PL_psig_ptr[sig]) || !(cv = MUTABLE_CV(SvRV(PL_psig_ptr[sig])))
75 0 if (!SvROK(PL_psig_ptr[sig]) || !(cv = MUTABLE_CV(SvRV(PL_psig_ptr[sig])))
3129 0 75 || SvTYPE(cv) != SVt_PVCV) {
3134 91 0 if (!cv || !CvROOT(cv)) {
2 89 if (!cv || !CvROOT(cv)) {
3135 2 0 Perl_ck_warner(aTHX_ packWARN(WARN_SIGNAL), "SIG%s handler \"%s\" not defined.\n",
3136 2 0 PL_sig_name[sig], (gv ? GvENAME(gv)
3137 0 0 : ((cv && CvGV(cv))
3138 0 0 ? GvENAME(CvGV(cv))
3139 0 0 : "__ANON__")));
3145 89 0 : newSVpv(PL_sig_name[sig],0);
3155 3 86 PUSHSTACKi(PERLSI_SIGNAL);
3156 0 89 PUSHMARK(SP);
3162 89 0 if (sigaction(sig, 0, &oact) == 0 && oact.sa_flags & SA_SIGINFO) {
1 88 if (sigaction(sig, 0, &oact) == 0 && oact.sa_flags & SA_SIGINFO) {
3188 89 0 errsv_save = newSVsv(ERRSV);
3192 0 86 POPSTACK;
3194 86 0 SV * const errsv = ERRSV;
3195 0 86 if (SvTRUE_NN(errsv)) {
0 86 if (SvTRUE_NN(errsv)) {
0 0 if (SvTRUE_NN(errsv)) {
0 0 if (SvTRUE_NN(errsv)) {
86 0 if (SvTRUE_NN(errsv)) {
86 0 if (SvTRUE_NN(errsv)) {
72 14 if (SvTRUE_NN(errsv)) {
0 72 if (SvTRUE_NN(errsv)) {
0 0 if (SvTRUE_NN(errsv)) {
0 0 if (SvTRUE_NN(errsv)) {
0 0 if (SvTRUE_NN(errsv)) {
0 0 if (SvTRUE_NN(errsv)) {
0 0 if (SvTRUE_NN(errsv)) {
0 0 if (SvTRUE_NN(errsv)) {
14 72 if (SvTRUE_NN(errsv)) {
3204 2 12 if (sip || uap)
3229 72 2 if (flags & 8)
3247 57669372 378600 if (!sv)
3250 57669372 0 if (SvTYPE(sv) >= SVt_PVMG && SvMAGIC(sv)) {
56200352 1469020 if (SvTYPE(sv) >= SVt_PVMG && SvMAGIC(sv)) {
3258 22788 56177564 if (mgs->mgs_readonly)
3260 55051721 1148631 if (mgs->mgs_magical)
3276 57290648 378724 if (PL_savestack_ix == mgs->mgs_ss_ix)
3285 57669372 0 if (bumped) {
3286 2 57669370 if (SvREFCNT(sv) == 1) {
3329 56038 466 : newSVpvn_flags(mg->mg_ptr, mg->mg_len, SVs_TEMP);
3364 16359 0 CopHINTHASH_set(&PL_compiling,
3404 1 0 if (nmg->mg_flags & MGf_REFCOUNTED) SvREFCNT_dec(nmg->mg_obj);