  Non-perturbative quantum corrections to supersymmetric black hole entropy
often involve nontrivial number-theoretic phases called Kloosterman sums. We
show how these sums can be obtained naturally from the functional integral of
supergravity in asymptotically AdS_2 space for a class of black holes. They are
essentially topological in origin and correspond to charge-dependent phases
arising from the various gauge and gravitational Chern-Simons terms and
boundary Wilson lines evaluated on Dehn-filled solid 2-torus. These corrections
are essential to obtain an integer from supergravity in agreement with the
quantum degeneracies, and reveal an intriguing connection between topology,
number theory, and quantum gravity. We give an assessment of the current
understanding of quantum entropy of black holes.
