docs: private void invokeScalarAlongDimension(ScalarOp op) {
          val dimension = op.dimensions().toIntVector();
          //dimension = Shape.normalizeAxis(op.x().rank(), dimension);
          // do tad magic
          /**
           * Returns the {@link Shape#createShapeInformation(int[], int[], int, int, char)}
           * and the associated offsets for each {@link INDArray#tensorAlongDimension(int, int...)}
           * The first item is the shape information. The second one is the offsets.
           */
          Pair<DataBuffer, DataBuffer> tadBuffers = tadManager.getTADOnlyShapeInfo(op.x(), dimension);
  
          Pointer hostTadShapeInfo = tadBuffers.getFirst().addressPointer();
          Pointer hostTadOffsets = tadBuffers.getSecond().addressPointer();
  
          Pointer devTadShapeInfoZ = null;
          Pointer devTadOffsetsZ = null;
          /**
           * Returns the {@link Shape#createShapeInformation(int[], int[], int, int, char)}
           * and the associated offsets for each {@link INDArray#tensorAlongDimension(int, int...)}
           * The first item is the shape information. The second one is the offsets.
           *
           * Note that this is the *result* TAD information. An op is always input (x) and output (z)
           * for result.
           * This is for assigning the result to of the operation along
           * the proper dimension.
           */
          Pair<DataBuffer, DataBuffer> tadBuffersZ = tadManager.getTADOnlyShapeInfo(op.z(), dimension);
  
          devTadShapeInfoZ = tadBuffersZ.getFirst().addressPointer();
          devTadOffsetsZ = tadBuffersZ.getSecond().addressPointer();
  
          if (extraz.get() == null)
              extraz.set(new PointerPointer(32));
  
          //PointerPointer dummy = extraz.get().put(hostTadShapeInfo, hostTadOffsets, devTadShapeInfoZ, devTadOffsetsZ);
  
  
          switch (op.getOpType()) {
              case SCALAR:
                  loop.execScalar(null, op.opNum(),
                          op.x().data().addressPointer(), (LongPointer) op.x().shapeInfoDataBuffer().addressPointer(),
                          null, null,
                          op.z().data().addressPointer(), (LongPointer) op.z().shapeInfoDataBuffer().addressPointer(),
                          null, null,
                          op.y().data().addressPointer(), (LongPointer) op.y().shapeInfoDataBuffer().addressPointer(),
                          null, null,
                          getPointerForExtraArgs(op, op.z().dataType()),
                          op.dimensions().data().addressPointer(),
                          (LongPointer) op.dimensions().shapeInfoDataBuffer().addressPointer(),
                          null,
                          null,
                          (LongPointer) hostTadShapeInfo, (LongPointer) hostTadOffsets,
                          (LongPointer) devTadShapeInfoZ, (LongPointer) devTadOffsetsZ);
                  break;
              case SCALAR_BOOL:
                  loop.execScalarBool(null, op.opNum(),
                          op.x().data().addressPointer(), (LongPointer) op.x().shapeInfoDataBuffer().addressPointer(),
                          null, null,
                          op.z().data().addressPointer(), (LongPointer) op.z().shapeInfoDataBuffer().addressPointer(),
                          null, null,
                          op.y().data().addressPointer(), (LongPointer) op.y().shapeInfoDataBuffer().addressPointer(),
                          null, null,
                          getPointerForExtraArgs(op, op.z().dataType()),
                          op.dimensions().data().addressPointer(),
                          (LongPointer) op.dimensions().shapeInfoDataBuffer().addressPointer(),
                          null,
                          null,
                          (LongPointer) hostTadShapeInfo, (LongPointer) hostTadOffsets,
                          (LongPointer) devTadShapeInfoZ, (LongPointer) devTadOffsetsZ);
                  break;
              default:
                  throw new UnsupportedOperationException();
          }
  
      }