Well, I did a quick and dirty random 4k read test on my SSDs using the AIDA64 Extreme software that came with my Crosshair X670E Extreme. It looks like there is a very good reason not to use the PCIe 4.0 connectivity if you can help it. That means the PCIe 4.0 x4 slot at the very end of the board and the CPU-facing side of the M.2 riser. They both come from the chipset.
Although the Intel Optane SSDs are all PCIe 3.0, they are still the fastest you can get for random I/O, so it illustrates the issue well:
Using the PCIe 4.0 M.2 slot dropped the random read speed from 305 MB/s to 281 MB/s for the Intel Optane 905P 380GB. You get a similar performance drop if you pick Best Power Efficiency from the Windows System Power Mode options.