There are hundreds, maybe thousands of papers on this exact topic. I left a note
from the paper mentioning this very thing.
It's up to you to explore this topic for yourself, if you choose.
---
Studies in nonhuman animals and younger human populations (infants/children) offer converging evidence that sex differences in empathy have phylogenetic and ontogenetic roots in biology and are not merely cultural byproducts driven by socialization. We review how these differences may have arisen in response to males' and females' different roles throughout evolution. Examinations of the neurobiological underpinnings of empathy reveal important quantitative gender differences in the basic networks involved in affective and cognitive forms of empathy, as well as a qualitative divergence between the sexes in how emotional information is integrated to support decision making processes.
--
from: Empathy: gender effects in brain and behavior
https://pubmed.ncbi.nlm.nih.gov/25236781/