I have a backup program that used to work reasonably well.
It used copyfileex to copy files from one unix machine to another.
Recently it has been maxing out at about 5Mb/s
So I changed to SHFileOperation and found it averages about 80Mb/s

This is using delphi 7 on windows 7.

So, is there a question here?

His question is why the rewritten stuff on Windows 7 works so much faster than what he had been using.

@OP:
You state that you are using CopyFileEx() (a Win API function) on Unix systems and it is going slow. Assuming your original code does not have any hooks on the call, it is at least going through an emulator (Wine, presumably), not to mention the overhead of going over network protocols.

You then state that you are using SHFileOperation() to have the Windows Shell perform the same function call and it is running faster, but on a native Windows 7 machine.

Without seeing your code for both the original and the rewritten stuff, I can only assume that playing with the OS emulator is costing you.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.