The choice of ProcessInfo.processInfo.systemUptime is discussed in apple/swift-corelibs-xctest#109 (search for mach_absolute_time in the conversation).
For a single source benchmark, you could still have a separate measure function, to contain the boilerplate code.
You could also put assert(false, "Compile with optimizations") at the top of the file, if you wanted to stop accidental -Onone results.