Timer1 Compare & Overflow setup

I'm looking to use Timer1 on an Arduino UNO for both a compare and overflow interrupt. How do I set up the registers to get both functionality?

Thank you

http://www.gammon.com.au/timers http://maxembedded.com/2011/06/introduction-to-avr-timers/ http://maxembedded.com/2011/07/avr-timers-ctc-mode/

The following actions could be taken as a part of initialization tasks:

bitSet(TIMSK1, 0);    //TC1 overflow interrupt is enabled

bitSet(TIMSK1, 1);   //TC1 Compare Match A interrupt is enabled

bitSet(TIMSK1, 2);  //TC1 Compare Match B interrupt is enabled

bitSet(SREG, 7);     //Global interrupt in enabled (it has already been done in init() of Arduino)

ISR(TIMER1_COMPA_vect)    //ISR for TC1 Compare Match A interrupt
{
   //codes
}

ISR(TIMER1_COMPB_vect)    //ISR for TC1 Compare Match B interrupt
{
   //codes
}


ISR(TIMER1_OVF_vect)    //ISR for TC1 overflow interrupt
{
   //codes
}

These files (file1, file2) may be consulted as reference document.