Ticket #1393: tt_1393_debug_prints2.diff
File tt_1393_debug_prints2.diff, 3.6 KB (added by lithos, 12 years ago) |
---|
-
src/ops/core.ops
467 467 Parrot_pcc_merge_signature_for_tailcall(interp, parent_call_sig, this_call_sig); 468 468 469 469 SUB_FLAG_TAILCALL_SET(interp->current_cont); 470 fprintf(stderr, "%s:%d: tailcall sub %p with continuation %p\n", 471 __FILE__, __LINE__, (void*)p, (void*)interp->current_cont); 470 472 dest = VTABLE_invoke(interp, p, dest); 471 473 goto ADDRESS(dest); 472 474 } -
src/pmc/retcontinuation.pmc
84 84 85 85 /* recycle this PMC and make sure it doesn't get marked */ 86 86 if (!PMC_IS_NULL(from_ctx)) 87 { 88 fprintf(stderr,"%s:%d: resetting continuation (SELF=%p) in context %p\n", 89 __FILE__, __LINE__, (void*)SELF, (void*)from_ctx); 87 90 Parrot_pcc_set_continuation(interp, from_ctx, NULL); 91 } 92 fprintf(stderr,"%s:%d: freeing myself (SELF=%p)\n", 93 __FILE__, __LINE__, (void*)SELF); 88 94 Parrot_gc_free_pmc_header(interp, SELF); 89 95 90 96 if (INTERP->code != seg) -
src/pmc/sub.pmc
21 21 #include "parrot/oplib/ops.h" 22 22 #include "sub.str" 23 23 24 static unsigned debug_counter = 0; 25 24 26 static void 25 27 print_sub_name(PARROT_INTERP, ARGIN_NULLOK(PMC *sub)) 26 28 { … … 379 381 ccont = INTERP->current_cont; 380 382 INTERP->current_cont = NULL; 381 383 384 fprintf(stderr, "%d: %s:%d: sub %p invoked with ccont %p\n", 385 debug_counter++, __FILE__, __LINE__, (void*)SELF, (void*)ccont); 386 387 #if 0 388 if (debug_counter-1 == 1592) 389 abort(); 390 #endif 391 382 392 if (ccont == NEED_CONTINUATION) 393 { 383 394 ccont = new_ret_continuation_pmc(interp, (opcode_t *)next); 395 fprintf(stderr, "created ret continuation %p\n", (void*)ccont); 396 } 384 397 385 398 PARROT_ASSERT(!PMC_IS_NULL(ccont)); 386 399 … … 395 408 Parrot_pcc_init_context(INTERP, context, caller_ctx); 396 409 397 410 Parrot_pcc_set_sub(interp, context, SELF); 411 fprintf(stderr, "%s:%d: setting continuation %p in context %p\n", 412 __FILE__, __LINE__, (void*)ccont, (void*)context); 398 413 Parrot_pcc_set_continuation(interp, context, ccont); 399 414 Parrot_pcc_set_constants(interp, context, sub->seg->const_table->constants); 400 415 -
src/gc/api.c
94 94 #include "parrot/gc_api.h" 95 95 #include "gc_private.h" 96 96 97 static unsigned debug_counter = 0; 98 97 99 /* HEADERIZER HFILE: include/parrot/gc_api.h */ 98 100 99 101 /* HEADERIZER BEGIN: static */ … … 401 403 pmc->vtable = NULL; 402 404 PMC_data(pmc) = NULL; 403 405 406 fprintf(stderr, "%d: created pmc %p\n", debug_counter++, (void*)pmc); 407 408 #if 0 409 if (debug_counter-1 == 28455) 410 abort(); 411 #endif 412 404 413 return pmc; 405 414 } 406 415 … … 421 430 Fixed_Size_Pool * const pool = (PObj_constant_TEST(pmc)) ? 422 431 interp->mem_pools->constant_pmc_pool : interp->mem_pools->pmc_pool; 423 432 433 fprintf(stderr, "%d: free pmc %p\n", debug_counter++, (void*)pmc); 434 435 #if 0 436 if (debug_counter-1 == 28480) 437 abort(); 438 #endif 439 424 440 Parrot_pmc_destroy(interp, pmc); 425 441 426 442 PObj_flags_SETTO((PObj *)pmc, PObj_on_free_list_FLAG);