I have done the matinee 3 times or more with Jet Lag. It is v. do-able IMO. I would not attempt the evening performance on landing day, however. I know I would fall asleep.
I am usually coming from Heathrow and with an earlier flight, so generally more time to get there. The big fly in the ointment, is, I think, getting to the hostel and then to the Globe. If you can find a place closer to the Globe (I have used the Premier Inn County Hall, though there is one closer to the Globe), then it might be reachable. Use Rome2Rio as a starting point from Gatwick to the Globe to get a picture of time. If you had an option to stay at the airport or to leave your bags at the airport, that might work, too.
That said, the matinee on Thursday is Two Noble Gentlemen. How often is that going to be playing vs how many opportunities for Hamlet? I think I would opt for the Thursday matinee, if that can fit into your overall scheme.