Statistical Inference of Optimal Allocations I: Regularities and their Implications