GetPooling2dForwardOutputDim returns wrong dimensions

I am using cuDNN v3 from F# from the ManagedCuda library. Here are the inputs:

let inputDescriptor = ObjectPool.getTensorDescriptor
let poolingDescriptor = ObjectPool.getPoolingDescriptor

let mutable n,c,h,w = 0,0,0,0
let dest_sizes = CudaDNN.CudaDNNNativeMethods.cudnnGetPooling2dForwardOutputDim(poolingDescriptor.Desc,inputDescriptor.Desc,&n,&c,&h,&w)

The above returns:

val inputDescriptor : TensorDescriptor
val poolingDescriptor : PoolingDescriptor
val mutable w : int = 9
val mutable n : int = 1
val mutable h : int = 9
val mutable c : int = 1
val dest_sizes : cudnnStatus = Success

There is something seriously wrong here and I am not sure what. Varying the windowHeight and windowWidth parameters does not make a difference in the output dimensions at all, varying padding by 1 only changes the num_rows and num_cols by 1 instead of 2. The stride parameter lacks a ceil at the end.

Maybe ignoring the function and calculating the output dimensions on my own would be okay, but this problem has me on edge. I’ve checked the wrapper library(ManagedCuda)'s function signatures and they match those in cudnn.h.

Any idea what this is about? I really wish cuDNN was not closed source.