Randomized Algorithms for Low-Rank Factorizations: Sharp Performance Bounds