/normxcorr/trunk

To get this branch, use:
bzr branch http://suren.me/webbzr/normxcorr/trunk

« back to all changes in this revision

Viewing changes to dict_hw/src/dict_hw.cu

  • Committer: Suren A. Chilingaryan
  • Date: 2010-08-09 00:10:31 UTC
  • Revision ID: csa@dside.dyndns.org-20100809001031-59vi0m04osiimrvz
Timing measurements are fixed, openmp support to accelerate image reduction

Show diffs side-by-side

added added

removed removed

Lines of Context:
952
952
        ctx->param_img = img;
953
953
    
954
954
        hw_sched_schedule_task(ctx->sched, ctx, dictLoadImageThread);
955
 
        
 
955
 
956
956
        if (ctx->preload&DICT_PRELOAD_REQUEST) {
957
 
            int preload_err = dictImageLoadImage(ctx, ctx->preload_request, ctx->image2);
 
957
            int preload_err;
 
958
            
 
959
# ifdef DICT_HW_MEASURE_TIMINGS
 
960
            gettimeofday(&tv2, NULL);
 
961
            ctx->time[5] += (tv2.tv_sec - tv1.tv_sec) * 1000000 + (tv2.tv_usec - tv1.tv_usec);
 
962
# endif /* DICT_HW_MEASURE_TIMINGS */
 
963
 
 
964
            preload_err = dictImageLoadImage(ctx, ctx->preload_request, ctx->image2);
958
965
            if (preload_err) {
959
966
                reportError("Failed to preload image %s, error %i. Ignoring and continuing...", ctx->preload_request, preload_err);
960
967
                ctx->preload = 0;
970
977
                
971
978
                ctx->preload = DICT_PRELOAD_READY;
972
979
            }
 
980
 
 
981
# ifdef DICT_HW_MEASURE_TIMINGS
 
982
            gettimeofday(&tv1, NULL);
 
983
# endif /* DICT_HW_MEASURE_TIMINGS */
973
984
        }
974
985
        
975
986
        hw_sched_wait_task(ctx->sched);