How is the 3 dimensional dot product computed for conv3d?

If possible can someone direct me to the routine that implements n dimensional dot product. There are ambiguities in the way 3d dot product is computed. Thanks.