Enzymes are complicated solvated systems that typically require many atoms to simulate their function with any degree of accuracy. We have recently developed numerical techniques for large scale first-principles molecular dynamics simulations and applied them to the study of the enzymatic reaction catalyzed by acetylcholinesterase. We carried out density functional theory calculations for a quantum-mechanical (QM) subsystem consisting of 612 atoms with an O(N) complexity finite-difference approach. The QM subsystem is embedded inside an external potential field representing the electrostatic effect due to the environment. We obtained finite-temperature sampling by first-principles molecular dynamics for the acylation reaction of acetylcholine catalyzed by acetylcholinesterase. Our calculations show two energy barriers along the reaction coordinate for the enzyme-catalyzed acylation of acetylcholine. The second barrier (8.5 kcal/mol) is rate-limiting for the acylation reaction and in good agreement with experiment.