If this is for gaming, both of the CPUs are easily enough, so it all comes down to the GPU.
This is why the fx 8320 + r9 290 would be better for gaming (IMHO) since it has a lot stronger GPU.
Matters on the game. If barely any cpu is used, the amd combo would be a better bang for the buck. BUT, if ANY cpu power is needed, the intel stomps the crap out of the amd. Amd is many generations behind now. It can easily be 20-30+ fps in favor of the Intel in some games. Again, matters what games. Look at CPU benchmarks. if there is little difference, the amd is a choice. If there is a big difference (intel is usually the winner), then the fastest cpu.
As my colleagues says, is more important to spend on the graphics card. Just one thing I want to suggest, get a FX 4350, it have 4,30 GHz, 300 mhz higher than the 8350, and since games does not use 8 cores, you get more performance for less money.