The Ryzen 5 1600AF is basically a 2nd generation processor so if you upgrade to a 3000 or 5000 series Processor it will be better.
If you Motherboard supports the 5000 series processor I would purchase that if not the 3000 series processor.
You can go to this website and see if your current 1600AF with the RX580 is bottlenecked: https://pc-builds.com/calculator/
Then input the 3000 and the 5000 Series Processor with the RX580 and see if the GPU or Processor is bottle necked or not.