SAN LUIS OBISPO, Calif. — Secel Montgomery Sr. stabbed a woman in the stomach, chest and throat so fiercely that he lost count of the wounds he inflicted. In the nearly 25 years he has been serving a life sentence, he has gotten into fights, threatened a prison official and been caught with marijuana.

Despite that, he has recently been entrusted with an extraordinary responsibility. He and other convicted killers at the California Men’s Colony help care for prisoners with Alzheimer’s disease and other types of dementia, assisting ailing inmates with the most intimate tasks: showering, shaving, applying deodorant, even changing adult diapers.

Their growing roster of patients includes Joaquin Cruz, a convicted killer who is now so addled that he thinks he sees his brother in the water of a toilet, and Walter Gregory, whose short-term memory is ebbing even as he vividly recalls his crime: stabbing and mutilating his girlfriend with a switchblade.

“I cut her eyes out, too,” Mr. Gregory declared recently.

Dementia in prison is an underreported but fast-growing phenomenon, one that many prisons are desperately unprepared to handle. It is an unforeseen consequence of get-tough-on-crime policies — long sentences that have created a large population of aging prisoners. About 10 percent of the 1.6 million inmates in America’s prisons are serving life sentences; another 11 percent are serving over 20 years.