implicit padding is implemented in three code paths:

CPU: https://github.com/pytorch/pytorch/blob/master/aten/src/THNN/generic/SpatialConvolutionMM.c 57 (look for padH, padW
CuDNN: no source code associated, as CuDNN is not open-source
CUDA (non-cudnn): https://github.com/pytorch/pytorch/blob/master/aten/src/THCUNN/generic/SpatialDilatedConvolution.cu 28 (look for padH, padW)

Out of curiosity, what are you planning to do?