message: dnn(ocl4dnn): fuseLayer() use umat_input/outputBlobs for OpenCL target
  Also, fix bug when use OPENCL target but no OpenCL runtime
diff: @@ -1196,7 +1196,8 @@ struct Net::Impl
  // some other layers.
  // TODO: OpenCL target support more fusion styles.
  - if ( preferableTarget == DNN_TARGET_OPENCL && ld.layerInstance->type.compare("Convolution") )
  + if ( preferableTarget == DNN_TARGET_OPENCL &&
  + (!cv::ocl::useOpenCL() || ld.layerInstance->type.compare("Convolution")) )
  continue;
  Ptr<Layer>& currLayer = ld.layerInstance;
  @@ -1214,6 +1215,9 @@ struct Net::Impl
  {
  printf_(("\tfused with %s\n", nextBNormLayer->name.c_str()));
  bnormData->skipFlags[DNN_BACKEND_DEFAULT] = true;
  + if ( preferableTarget == DNN_TARGET_OPENCL )
  + ld.umat_outputBlobs = layers[lpNext.lid].umat_outputBlobs;
  + else
  ld.outputBlobs = layers[lpNext.lid].outputBlobs;
  if( bnormData->consumers.size() == 1 )
  {
  @@ -1234,6 +1238,9 @@ struct Net::Impl
  {
  printf_(("\tfused with %s\n", nextScaleLayer->name.c_str()));
  scaleData->skipFlags[DNN_BACKEND_DEFAULT] = true;
  + if ( preferableTarget == DNN_TARGET_OPENCL )
  + ld.umat_outputBlobs = layers[lpNext.lid].umat_outputBlobs;
  + else
  ld.outputBlobs = layers[lpNext.lid].outputBlobs;
  if( scaleData->consumers.size() == 1 )
  {
  @@ -1263,6 +1270,9 @@ struct Net::Impl
  LayerData *activData = nextData;
  printf_(("\tfused with %s\n", nextActivLayer->name.c_str()));
  activData->skipFlags[DNN_BACKEND_DEFAULT] = true;
  + if ( preferableTarget == DNN_TARGET_OPENCL )
  + ld.umat_outputBlobs = layers[lpNext.lid].umat_outputBlobs;
  + else
  ld.outputBlobs = layers[lpNext.lid].outputBlobs;
  if ( preferableTarget == DNN_TARGET_OPENCL )
  @@ -1325,13 +1335,13 @@ struct Net::Impl
  !nextData->type.compare("Power")) &&
  currLayer->setActivation(nextActivLayer) )
  {
  - CV_Assert(firstConvLayerData->outputBlobs.size() == 1 && ld.inputBlobs.size() == 1);
  - ld.inputBlobs.push_back(&firstConvLayerData->outputBlobs[0]);
  + CV_Assert(firstConvLayerData->umat_outputBlobs.size() == 1 && ld.umat_inputBlobs.size() == 1);
  + ld.umat_inputBlobs.push_back(firstConvLayerData->umat_outputBlobs[0]);
  printf_(("\tfused with %s\n", nextEltwiseLayer->name.c_str()));
  printf_(("\tfused with %s\n", nextActivLayer->name.c_str()));
  eltwiseData->skipFlags[DNN_BACKEND_DEFAULT] = true;
  nextData->skipFlags[DNN_BACKEND_DEFAULT] = true;
  - ld.outputBlobs = layers[lpNext.lid].outputBlobs;
  + ld.umat_outputBlobs = layers[lpNext.lid].umat_outputBlobs;
  }
  }
  }
  