PSX ends on a positive note after 500-point swing