Memory Profiling For Mere Mortals

Sampling Memory Allocations

exports.innerOuterArray = function innerOuterArray() {
  const arr = []
  const OUTER_ITER = ITER / 20
  const INNER_ITER = OUTER_ITER * 10

  for (let j = 0; j < OUTER_ITER; j++) {
    let innerArr = []
    for (let i = 0; i < INNER_ITER; i++) {
      innerArr.push({ i: i })
    }
    arr.push(innerArr)
  }
  return arr
}