#1765: Memory leak in allocate_interpreter
-----------------------+----------------------------------------------------
 Reporter:  nwellnhof  |        Owner:  bluescreen
     Type:  bug        |       Status:  reopened  
 Priority:  normal     |    Milestone:            
Component:  core       |      Version:  trunk     
 Severity:  medium     |   Resolution:            
 Keywords:             |         Lang:            
    Patch:             |     Platform:            
-----------------------+----------------------------------------------------
Changes (by nwellnhof):

  * status:  closed => reopened
  * resolution:  fixed =>


Old description:

> {{{
> $ valgrind --leak-check=full ./parrot t/op/interp_2.pir
> [...]
> ==22134== 789,400 (212 direct, 789,188 indirect) bytes in 1 blocks are
> definitely lost in loss record 1,075 of 1,075
> ==22134==    at 0x402328F: calloc (vg_replace_malloc.c:467)
> ==22134==    by 0x40877B9: mem_sys_allocate_zeroed (alloc_memory.c:83)
> ==22134==    by 0x4090788: allocate_interpreter (inter_create.c:124)
> ==22134==    by 0x40908C8: make_interpreter (inter_create.c:92)
> ==22134==    by 0x40DB6CC: create_interp (parrotinterpreter.pmc:183)
> ==22134==    by 0x40DB7C8: Parrot_ParrotInterpreter_init
> (parrotinterpreter.pmc:252)
> ==22134==    by 0x40BAB52: Parrot_pmc_new (pmc.c:164)
> ==22134==    by 0x4069CC2: Parrot_new_p_sc (core_ops.c:20664)
> ==22134==    by 0x40BBE74: runops_slow_core (cores.c:647)
> ==22134==    by 0x40BB78D: runops_int (main.c:237)
> ==22134==    by 0x409116C: runops (ops.c:127)
> ==22134==    by 0x408D2D6: Parrot_pcc_invoke_from_sig_object (pcc.c:325)
> ==22134==
> }}}

New description:

 {{{
 $ valgrind --leak-check=full ./parrot --leak-test t/op/interp_2.pir
 [...]
 ==4748== 131,364 (216 direct, 131,148 indirect) bytes in 1 blocks are
 definitely lost in loss record 184 of 184
 ==4748==    at 0x402328F: calloc (vg_replace_malloc.c:467)
 ==4748==    by 0x40F262B: mem_sys_allocate_zeroed (alloc_memory.c:82)
 ==4748==    by 0x4108184: allocate_interpreter (inter_create.c:123)
 ==4748==    by 0x410813A: make_interpreter (inter_create.c:91)
 ==4748==    by 0x416FFED: create_interp (parrotinterpreter.pmc:182)
 ==4748==    by 0x41708C8: Parrot_ParrotInterpreter_init
 (parrotinterpreter.pmc:251)
 ==4748==    by 0x413BCAB: Parrot_pmc_new (pmc.c:163)
 ==4748==    by 0x40B8F13: Parrot_new_p_sc (core_ops.c:20494)
 ==4748==    by 0x413E780: runops_slow_core (cores.c:646)
 ==4748==    by 0x413D7F9: runops_int (main.c:218)
 ==4748==    by 0x41098EE: runops (ops.c:126)
 ==4748==    by 0x4103CCA: Parrot_pcc_invoke_from_sig_object (pcc.c:323)
 }}}

--

Comment:

 The leak can be reproduced with the --leak-test option. Description
 updated.

-- 
Ticket URL: <https://trac.parrot.org/parrot/ticket/1765#comment:8>
Parrot <https://trac.parrot.org/parrot/>
Parrot Development
_______________________________________________
parrot-tickets mailing list
[email protected]
http://lists.parrot.org/mailman/listinfo/parrot-tickets

Reply via email to