hello Chrisv,
TRV, a stamp on your passport and study permit/work permit are different things all together. TRV is required to enter Canada, However, study/work permit determines length of your stay in Canada.
Now lets udnerstand this with an example. I am an International Student with 1 year TRV staring Jan.01, 2014 and it ends on Dec. 31, 2014. I flunked or skipped or for any other valid reason, couldn't complete my program within 1 year. What I will do now is I will apply for extension of my study permit which will cost me 140 CAD and I do not need another TRV stamped just another study permit will be issued with the time mentioned by which I will complete my study.
Now, lets talk about your particular case, as your TRV ends on 31.05.2015 and you will have another 3 weeks to stay in Canada. Now, once you complete your study say on 31.05.2015, you have another 90 days period to either apply for work permit or another study permit. So you need not panic or worry about it and you will not be staying as illegal immigrant (as you will officially have 90 days period to apply). So you don't have to worry about a grace period of another 1 month or two months to attend convocation or to receive transcripts.
Hope it makes things bit clear.
Cheers!