I've done this twice & never had any issues. I did it this way because I've never had the main panel inside the garage.
Ran 10/3 from the main panel to a sub panel in the garage on a 70 amp breaker. The sub panel is set up for the welders & air compressor each on its own 30 amp breaker.
You could get away with just a 30 amp on the main panel with 10/3 to an outlet in your garage. I only did it my way for easy maintenance if it's required.
Often times the machine will stop itself before the breaker does. But if the manufacturer suggests a 40 amp then I'd go with that.
View attachment 526451