The "what would you like it to be?" sort
- Note the system time.
- Sort using Quicksort (or anything else reasonably sensible), omitting the very last swap.
- Note the system time.
- Calculate the required time. Extended precision arithmetic is a requirement.
- Wait the required time.
- Perform the last swap.
Not only can it implement any conceivable O(x) value short of infinity, the time taken is provably correct (if you can wait that long).