What is the function of the capacitor in this circuit?
R3 is to pull the gate up close to source potential when Q2 is turned off (which turns Q1 off).

Q2 pulls the gate down to ground potential to turn Q1 on (the gate will be at -Vcc with respect to the source). 

C1 uses up PCB real estate, costs money, and does nothing of any value.  It just slows down the turn-off of Q1 a bit, and the turn-on hardly so you would notice it.