lib/compile.js
function countMatches(orders) {
  var matched = 0, dimension = orders[0].length
  while(matched < dimension) {
    for(var j=1; j<orders.length; ++j) {
      if(orders[j][matched] !== orders[0][matched]) {
        return matched
      }
    }
    ++matched
  }
  return matched
}
function countMatches(orders) {
  var matched = 0, dimension = orders[0].length
  while(matched < dimension) {
    for(var j=1; j<orders.length; ++j) {
      if(orders[j][matched] !== orders[0][matched]) {
        return matched
      }
    }
    ++matched
  }
  return matched
}
function countMatches ( orders ) { var matched = 0 , dimension = orders [ 0 ] . length while ( matched < dimension ) { for ( var j = 1 ; j < orders . length ; ++ j ) { if ( orders [ j ] [ matched ] !== orders [ 0 ] [ matched ] ) { return matched } } ++ matched } return matched }
Count the number of compatible inner orders This is the length of the longest common prefix of the arrays in orders. Each array in orders lists the dimensions of the correspond ndarray in order of increasing stride. This is thus the maximum number of dimensions that can be efficiently traversed by simple nested loops for all arrays.
Count the number of compatible inner orders This is the length of the longest common prefix of the arrays in orders . Each array in orders lists the dimensions of the correspond ndarray in order of increasing stride . This is thus the maximum number of dimensions that can be efficiently traversed by simple nested loops for all arrays .