I, along with board members, was surprised to hear from the director of gifted ed that there is a huge discrepancy in the number of boys vs girls in gifted math across the district -- 75% boys vs 25% girls.
If they are testing in the third grade and have a higher cut off, like 99th percentile, then by that time, I think that sounds plausible, particularly if you live in an area where boys and girls are held strongly to traditional gender roles.
The thing is, boys are playing more sports with balls (spatial knowledge), boys are given tens more sets of legos (girls get dollies), and they have already had three to four years of implicit bias from teachers to get to the girls.
Not to mention, however we strive to close this gap, at the top .05% of performers in math, the difference between male and female scores is one of the most persistent found in education, across countries, cultures. It's not getting smaller, unlike the differences between average people, for which there are no statistically significant differences if you take multi-nation surveys. Note that among average learners, that difference should be easier to find and more significant due to much higher populations.
There is something about those kids at the far end of the math spectrum. Either boys are truly genetically predisposed to math, or, just as likely based on my experience, we get to those girls very early and they are smart enough to start questioning whether a girl can really do this.
Some experiments in which girls were prepped to think that "this is a test girls do well on", when boys were told that "this kind of math is female-oriented", showed that with such preparation, girls outperformed boys. (The math was from standard assessment tests.) So that self-assessment bias can play a huge role.
Source: I do analytics on education and other social work for a living. I am a woman in a math field and believe me it kills me to say it but it's there. I hate that girls do worse but you cannot explain it away at those high performing levels. It is something that's being looked into. Still, when your three-year-old daughter comes home and asks why she's the only girl in the lego club, and how the boys didn't let her do anything, so she doesn't want to go anymore, and this is in one of the richest, most liberal parts of the world, well... you can kind of believe it just MIGHT be bias against high-performing girls. They can sense our doubt, they can sense that it's not "their" turf.
Incidentally, boys likewise perform much worse than girls verbally. I've always wondered if low verbal IQ helps you do well on math tests, because I've noticed that the questions are very vague, but if you ignore the words and just try to solve every problem like a puzzle, you can do much better. (I did this as a child, and did score with the top boys.)
What if the bias is against boys verbally, because of how their parents relate to them, but that helps them in math tests, which are written by other people with poor verbal IQs?
Fascinating stuff but there are no easy answers.