There are tradeoffs for both, the 12100f is suffering from being a quad core cpu and 1080p will be far more effected by cpu than 1440p or 4k, so this is a good choice especially if upscaling doesn't bother you, on the other hand a gpu upgrade will be a tangible upgrade as well, as gpu upgrades have more immediate effects in gaming for cpu's that use 4 cores or less, but is mostly a games upgrade.
Personally i'd go for the cpu upgrade, don't need to go for something extremely high like a 12900k, a 12600k(or 14600k, if your motherboard supports a bios update to slot it) is probably enough to avoid any cpu bottlenecks in gaming, but neither is a bad choice.