Pushed, thanks.
> -----Original Message----- > From: Beignet [mailto:[email protected]] On Behalf Of > Weng, Chuanbo > Sent: Tuesday, March 29, 2016 11:04 > To: [email protected]; [email protected] > Subject: Re: [Beignet] [PATCH] Add condition checking of residuals because it > may be NULL. > > LGTM, thanks. > > -----Original Message----- > From: Beignet [mailto:[email protected]] On Behalf Of > [email protected] > Sent: Monday, March 28, 2016 3:35 PM > To: [email protected] > Cc: Yan Wang <[email protected]> > Subject: [Beignet] [PATCH] Add condition checking of residuals because it > may be NULL. > > From: Yan Wang <[email protected]> > > --- > src/kernels/cl_internal_block_motion_estimate_intel.cl | 9 ++++++--- > 1 file changed, 6 insertions(+), 3 deletions(-) > > diff --git a/src/kernels/cl_internal_block_motion_estimate_intel.cl > b/src/kernels/cl_internal_block_motion_estimate_intel.cl > index 23c5488..e56520a 100644 > --- a/src/kernels/cl_internal_block_motion_estimate_intel.cl > +++ b/src/kernels/cl_internal_block_motion_estimate_intel.cl > @@ -341,7 +341,8 @@ void > block_motion_estimate_intel(accelerator_intel_t accel, > mv_index = index * 1; > if( lid_x == 0 ){ > motion_vector_buffer[mv_index] = mv[lid_x]; > - residuals[mv_index] = 2 * res[lid_x]; > + if(residuals) > + residuals[mv_index] = 2 * res[lid_x]; > } > } > //CL_ME_MB_TYPE_8x8_INTEL > @@ -350,7 +351,8 @@ void > block_motion_estimate_intel(accelerator_intel_t accel, > mv_index = lgid_y * num_groups_x * 4 + lgid_x * 2; > mv_index = mv_index + num_groups_x * 2 * (lid_x / 2) + (lid_x % 2); > motion_vector_buffer[mv_index] = mv[lid_x]; > - residuals[mv_index] = 2 * res[lid_x]; > + if(residuals) > + residuals[mv_index] = 2 * res[lid_x]; > } > } > //CL_ME_MB_TYPE_4x4_INTEL > @@ -359,7 +361,8 @@ void > block_motion_estimate_intel(accelerator_intel_t accel, > mv_index = lgid_y * num_groups_x * 16 + lgid_x * 4; > mv_index = mv_index + num_groups_x * 4 * (lid_x / 4) + (lid_x % 4); > motion_vector_buffer[mv_index] = mv[lid_x]; > - residuals[mv_index] = 2 * res[lid_x]; > + if(residuals) > + residuals[mv_index] = 2 * res[lid_x]; > } > } > > -- > 2.5.0 > > _______________________________________________ > Beignet mailing list > [email protected] > https://lists.freedesktop.org/mailman/listinfo/beignet > _______________________________________________ > Beignet mailing list > [email protected] > https://lists.freedesktop.org/mailman/listinfo/beignet _______________________________________________ Beignet mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/beignet
