I am recompiling a old Delphi program (from Delphi 2007) in (Delphi 2010). The code is absolutely unchanged and it compiles well. The key part of the program is the use of CopyFileExW to copy some files. Everything works OK and Dandy, however, there are some strange performance problems that I cannot understand where they come from.
When copying from a client computer to a Windows server the following happens:
- Version compiled with D2007
- From XP to Windows Server 2003, Copy performance OK
- From XP to Windows Server 2008 Copy performance OK
- From Windows 7 to Windows Server 2003, Copy performance OK
From Windows 7 to Windows server 2008 Copy performance OK
Version compiled with Delphi 2010
- From XP to Windows Server 2003, Copy performance OK
- From XP to Windows Server 2008 Copy performance OK
- From Windows 7 to Windows Server 2003, Copy performance OK
- From Windows 7 to Windows server 2008 Copy performance EXTREMLY SLOW
I can understand that perhaps there is an issue between the 2008 server and W7, like Remote Differential Compression or such (which BTW is disabled), but why does the version compiled with 2007 doesn't have the same problem? Any 开发者_Python百科guesses?
Some ideas of possible causes:
AntiVirus software on WS2008 side thinking that the transfer is suspicious and making verifications (as already stated in the comments).
Possibly some implicit string conversion getting in the way.
Since you are just now updating a program to run on Delphi 2010, you should probably go to Delphi XE and start solving problems there. It comes with a profiler built in AND you get to work with the newest stuff.
精彩评论