My 2e (gifted/Asperger's) son has some of the attention and executive function issues you describe. Kids on the spectrum spend a lot of time in their own heads, thinking about their special interest topics in detail-- it's hard to get them out of that headspace to attend to the things the school staff wants them to attend to.

This isn't always a problem with the school; sometimes it's a matter of the child learning to manage their own attention and follow directions appropriately, which is very challenging but worth learning to do. Of course, appropriate supports at school can be crucial to learning those skills for those kids to whom it doesn't come naturally.

Mich gave good advice above-- I agree with it.

DeeDee