It sounds like your muscle cramps happen towards the beginning of your day of riding. This makes sense, because often muscle cramping associated with use of those muscles is more likely to happen when the muscles are not warmed up.
When you ride your dirt bike, the use of these muscles is not constant. You probably squeeze down on the handles really tight when you accelerate, but let go when coasting a bit. At the beginning of your ride, the forearm muscles are not getting enough blood flow to accommodate those times when they are working very hard. Thus when you squeeze down, they are more likely to go into a spasm (cramp) when they are working with inadequate nutrients and oxygen. You can help prevent this by doing some forearm exercises prior to getting on the bike. This way your muscles will already have the higher blood flow they need. Other causes of cramping to be considered are abnormal potassium levels and abnormal calcium levels in your blood. It is not clear from your story if these could be playing a role.
I think this is an issue you can bring up with your
primary care physician at your next visit. The two of you can discuss other methods to prevent this and also discuss the important issues surrounding dirt bike safety.