A Canadian Temporary Resident Visa is an authorization to enter Canada and it expires once you enter the country (in the case of the single entry ones, very uncommon these days) or when the deadline is passed (if you have a multiple entry visa, usually issued in 90% of the cases).
When you get your visa you will notice a period of validity on it. Many people think that they have to get in and out during that period. False. You are authorized to enter Canada before the deadline, but you can stay longer. The maximum length of stay is usually 6 months, unless the border agent puts a different date under the entry stamp.
Let’s say for instance that your visa says 22/12/2001 – 30/06/2002 just like in the picture. This is the validity of the visa, which means you can enter Canada even on the last day of June.
From that point you can stay in Canada for 6 months if your entry stamp looks like the left one in the picture. However in some cases the officer may consider that you should leave earlier, so he will put a note under your stamp.
It is very important to leave Canada before your status expires; failure to do so can have serious consequences. Therefore if you plan to stay longer, you should apply for extension one month before deadline.