Roger Federer has won a record 17 Grand Slam titles over his career but has struggled of late.