Hi, I am trying to bind a datatable to ultragrid via C# in an windows application. The datatable contains 60,000 rows and 20 columns. The binding time (in milliseconds) for 32 BIT (2 GB RAM) and 64 BIT (4GB RAM, same processors) systems is as given below:
As is evident from the data, though the system configuration of 32 bit machine is inferior to the 64 bit machine, time taken for 64 bit machine is more. Is it because I am using a 32 BIT Infragistics dll for the 64 BIT system. Is there any 64 bit dll for infragistics? Please Help.....
Normal 0 false false false MicrosoftInternetExplorer4
TRIAL #
64BIT
32 BIT
1
812
453
2
796
421
3
781
4
687
5
437
6
7
8
AVG.
765.125
429.000
You actually don't need to explicitly target x64 when compiling a .NET assembly. The assemblies are compiled into MSIL code which will then be "compiled" for a particular processor or architecture dynamically when they are loaded. You can verify this by looking at c:\windows\assembly on your comptuer using a command window. Notice that there are a few different folders - GAC, GAC_32, GAC_64, GAC_MSIL. The Infragistics assemblies will be in GAC_MSIL since they're compiled for use on "ANY" platform.
As for performance differences, there could be a lot of reasons. The x64 compiler may be slower than the x86 compiler. It may be the larger spaces of unused memory. It could be the longer time it takes to do simple arithmatic with the larger memory address spaces, etc. While X64 improves performance in some scenarios it's real benefit is allow us to pass the previous memory barrier we were facing with a 32 bit architecture. I believe 4GB of ram was the most you would get out of a x86 architecture since the memory address over 4GB becomes longer than 32bytes in length.
If you google x64 vx. x86, you'll see lots of posts about how apps run slower on x64. The main reason you're seeing perf improvements is because you've doubled your ram on your x64 box. Had you done that on the x86 machine, I think you probably would have seen similar results.
Hope this helps,
-Tony
Unfortunately, I don't really have any suggestions on how to speed this up on a 64bit machine. It's possible that compiling the NetAdvantage DLLs to target an x64 OS will speed the application up, but I do not know this for sure. Your best option is to submit a small sample to Developer Support so that they can have someone look into it.
-Matt
Hi Matt, Thanks for your reply.
I tested the same with a .NET DataGridView, and the comparison of time in milliseconds to databind the datatable (60000 rows and 20 columns) to the datagridview is given below.
So the performance of datagridview on 64 bit system is better than that for 32 bit system. But we need the ultragrid for our project as it supports the multi band structure. Please advise....
I wasn't able to back this up with a quick search at this time, but when I was deciding to go to 64bit, my research indicated that 4gb with 64bit was more or less a waste of time, the minimum step up from 32bit with 2gb of ram was to go to 64bit with 8gb. The truth being that x64 uses a lot more memory than x86, but with today's memory prices this isn't much of an issue since you can now get 8gigs for less than $100. My understanding is that a lot of memory is only partially used in x64 installations since a lot of data doesn't fill individual 64bit "words" completely (I know "words" is not the technically correct term, is it "registers"?).
This is what I've done and have been very glad. I have not performance tested exact same hardware with alternate install of 32 vs 64, and since my development machine is much faster than my user's machines I don't feel much pressure to measure performance that way. A lot of tasks I do run only about the same speed as they did on my previous x86 setup, but so many more run much faster. I can now have 4 or 5 instances of Visual Studio running for hours at a time, and any of them still close in a second or so, where it sometimes used to take almost 20 or more seconds if a lot of what windows was juggling had been cached out to page file.
Bob Graham
Do you get similar results when binding to a .NET DataGridView? I recall seeing some performance benchmarks a while back related to the fact that much of the performance increase was actually in the .NET code that the particular application used through binding, though since this was a while ago, I'm afraid that I don't remember the specifics. There are no 64bit-specific versions of NetAdvantage, but you could certainly target your application to compile for 64bit; furthermore, I do not believe that any of the .NET DLLs themselves are compiled for a x64. As a final note, since 32bit applications will run through the WOW64 emulation layer on an x64 machine, it is expected that there may be a performance hit (though these numbers seem rather high to attribute to that).