varnamproject-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Varnamproject-discuss] Improve the learning system


From: Navaneeth K N
Subject: Re: [Varnamproject-discuss] Improve the learning system
Date: Fri, 07 Mar 2014 09:59:31 +0530
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:24.0) Gecko/20100101 Thunderbird/24.3.0

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512



On 3/7/14 3:41 AM, Jaydeep Singh wrote:
> Form my understanding of source code, the vpool here is the initialised
> resource that we are keeping for use, rather than allocating and destroying
> again and again as suggested by these function:
> void*
> vpool_get(vpool *pool);
> 
> void
> vpool_add(vpool *pool, void *item);
> 
> void
> vpool_return(vpool *pool, void *item);
> 
> Program requests an item from the vpool and perform operations on the
> returned item. When it has finished with an item (or resource), it returns
> it to the vpool, rather than destroying it. Am I correct in context? Please
> guide.
> 

You are absolutely correct. It essentially reduces the amount of
`malloc` calls made.

- -- 
Cheers,
Navaneeth
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.22 (Darwin)
Comment: GPGTools - https://gpgtools.org

iQEcBAEBCgAGBQJTGUsrAAoJEHFACYSL7h6kUP4H/ioVMNf5uleAuk5RL5V3MBI3
zH4LRpWIZ7DZG+SURQ/1GhW5eeegTeku701zk8XhUg49Xud6hT5tif8g/6NAi+pi
lk8vtFRnunMX0FsGkMPrPBST64R9IG79BqFBJIdP/y3fRaSe6XKiJAYX32klqkZM
3PDObvcqIco9xXUtPu3r013i/S5/Q/fG+tP2CZGQsQGONrxaCcFVrjy/kAHqEvQx
3VQMOYk7eRgiak75Mhcodh+x512CtJmeiM5eg/cPnKU42uc9CBCfprPnl4FiVEXk
VtIKwPF06rja+W4tWbkkB+cbiI+we0W1Q3hP79LTLMTlaUlmZXr1R4Up0Qi8qak=
=iMiG
-----END PGP SIGNATURE-----



reply via email to

[Prev in Thread] Current Thread [Next in Thread]