On Thu, Mar 22, 2018 at 07:57:54PM +0800, Xiao Guangrong wrote:
>
>
> On 03/21/2018 05:06 PM, Peter Xu wrote:
> > On Tue, Mar 13, 2018 at 03:57:33PM +0800, guangrong.x...@gmail.com wrote:
> > > From: Xiao Guangrong
> > >
> > > Current code uses
On 03/21/2018 05:06 PM, Peter Xu wrote:
On Tue, Mar 13, 2018 at 03:57:33PM +0800, guangrong.x...@gmail.com wrote:
From: Xiao Guangrong
Current code uses compress2()/uncompress() to compress/decompress
memory, these two function manager memory allocation and
On Tue, Mar 13, 2018 at 03:57:33PM +0800, guangrong.x...@gmail.com wrote:
> From: Xiao Guangrong
>
> Current code uses compress2()/uncompress() to compress/decompress
> memory, these two function manager memory allocation and release
> internally, that causes huge
On 03/19/2018 06:54 PM, Dr. David Alan Gilbert wrote:
+return 0;
+exit:
+compress_threads_load_cleanup();
I don't think this is safe; if inflateInit(..) fails in not-the-last
thread, compress_threads_load_cleanup() will try and destroy all the
mutex's and condition variables, even
* Xiao Guangrong (guangrong.x...@gmail.com) wrote:
>
>
> On 03/15/2018 07:03 PM, Dr. David Alan Gilbert wrote:
>
> > > +static int compress_threads_load_setup(void)
> > > +{
> > > +int i, thread_count;
> > > +
> > > +if (!migrate_use_compression()) {
> > > +return 0;
> > > +
On 03/15/2018 07:03 PM, Dr. David Alan Gilbert wrote:
+static int compress_threads_load_setup(void)
+{
+int i, thread_count;
+
+if (!migrate_use_compression()) {
+return 0;
+}
+
+thread_count = migrate_decompress_threads();
+decompress_threads = g_new0(QemuThread,
* guangrong.x...@gmail.com (guangrong.x...@gmail.com) wrote:
> From: Xiao Guangrong
>
> Current code uses compress2()/uncompress() to compress/decompress
> memory, these two function manager memory allocation and release
> internally, that causes huge memory is