//+------------------------------------------------------------------+ //| MatrixMult.mq5 | //| Copyright 2000-2025, MetaQuotes Ltd. | //| https://www.mql5.com | //+------------------------------------------------------------------+ #property copyright "Copyright 2000-2025, MetaQuotes Ltd." #property link "https://www.mql5.com" #property version "1.00" #include //--- OpenCL kernels #resource "Kernels/matrixmult.cl" as string cl_program #define BLOCK_SIZE 10 //+------------------------------------------------------------------+ //| MatrixMult_CPU | //+------------------------------------------------------------------+ bool MatrixMult_CPU(const float &matrix_a[],const float &matrix_b[],float &matrix_c[], const int rows_a,const int cols_a,const int cols_b,ulong &time_cpu) { int size=rows_a*cols_b; if(ArrayResize(matrix_c,size)!=size) return(false); //--- CPU calculation started time_cpu=GetMicrosecondCount(); for(int i=0; i