Section 76A. Any person retired under the provisions of section seventy-five shall receive an annual pension equal to one half of the regular annual compensation received by him at the time of his retirement; provided, that any such person who is retired after attaining age sixty-five and who has given his whole time to the duties of the office of probation officer and has faithfully performed such duties for a period of not less than twenty consecutive years immediately preceding his retirement shall receive an annual pension equal to one half of the regular annual compensation received by him at the time of his retirement and an additional yearly amount equal to one per cent of said compensation for each year after the first twenty, the total yearly amount of his pension not to exceed sixty-five per cent of said regular annual compensation. Such pension shall be paid by the county in which such person has performed his duties, or if he has performed such duties in more than one county, it shall be apportioned by the superior court among such counties.