Is 64-bit platform always better than 32-bit?


I recently did some preliminary performance testing on the 64-bit platform Vs that on 32-bit. Here are the results of the same













































































































 


Calculation Speed (milliseconds)


Memory Copy (milliseconds)


Measure


x86


x64


IA64


x86


x64


IA64


Iterations


100000


5.51


0.31


0.7


 


 


 


1000000


59.73


7.64


15.5


 


 


 


10000000


594.74


68.38


150.5


 


 


 


100000000


5822.93


1100.83


1568.84


 


 


 


Memory


512KB


 


 


 


1.1


0.62


1.3


1MB


 


 


 


2.02


0.62


3.6


32MB


 


 


 


74.21


8.1


103.9


64MB


 


 


 


154.61


79.42


181.2


128MB


 


 


 


331.55


154.66


456.6


256MB


 


 


 


660.01


303.92


915.42


512MB


 


 


 


25931


6421.32


19302.94


Note: In order to get stable results for the performance tests, the results as above are averaged of around 100 executions on each platform for each kind of operation.


The iterations for Calculation Speed were performed on the IL instruction set
   IL_0060:  ldloc.0
  IL_0061:  ldloc.2
  IL_0062:  mul
  IL_0063:  ldc.i4     0x2ab9274a
  IL_0068:  conv.i8
  IL_0069:  div
  IL_006a:  stelem.i8
which corresponds to a calculation between variables and storing the result in an array of type long[]. (myArr1[i] = ((var1 * var3) / 716777290))


The Memory Copy operation included copy between two arrays with the following IL instruction set
   IL_008a:  ldelem.i8
  IL_008b:  stelem.i8
which corresponding to copying from one array to another. (myArr2[i] =myArr1[i])



Observations
• Both x64 and IA 64 platforms have a definite improvement in the calculation speed when compared to the x86 platform by as much as 5.3 times and 3.7 times respectively.
• Memory access and copying operation for sizes equal to and lesser than 256MB was most efficient on x64 platform, followed by x86 and then IA64. This is an anomaly in the sense that IA64’s performance was not even as good as x86 platform. While x64 platform was faster than x86 platform by 2.1 times, the IA64 was slower by around 0.67 times.
• Memory access and copying operation for 512MB was most efficient on x64 platform, followed by IA64 and then x86. x64 was around 4 times faster than x86 platform and IA 64 was faster by around 1.34 times when compared to x86 platform.


Machine Configuration:
The machines that I used for this testing had the following configurations
• x86 machine: 1 GB RAM on a 2 GHz machine
• x64 machine: 1 GB RAM on a 2.8 GHz machine
• IA64 machine: 1GB RAM on a 997 MHz machine


Though the above data suggests some performance improvement in 64-bit as compared to the 32-bit, a lot more needs to be done in terms of standardization and acceptance of what works better and what does not on 64-bit-bit platforms when compared to the 32-bit platform.


There are certain known areas where 64-bit platform does not do too well.


So the above observations and findings from my side are not complete enough to be able to announce one of the two platforms as a winner. There is still a lot more that I should and would be doing to find out more.


I would cover that and much more about this topic in my next few blogs. So in case, you are interested - stay connected.


But, the best would be to share your experiences with all. So looking ahead to hear back from the enthusiasts.

Comments (4)

  1. aq says:

    wow

    i’ve been an amd partisan for some time but these results are still surprising. in the short term, the x64 strategy is what i am going to recommend for the transition phase.

  2. Ummmm… As much as I’m an AMD Fanboy (and I run x64 as my *HOME* OS), your results are questionable.  What actual processors are you using?  (I don’t recall AMD making a 2.8 Ghz x64 box yet).  Are all three processors from the same manufacturer?  Why not run the x86 and x64 on the same box with different OS to give x86 and x64 equal footing?

  3. GauravS says:

    Yes David, you are correct! The box that I used was not an AMD box. It was an x64 box running on a Pentium D processor. I would carry out the testing (x86 and x64 on the same box) as suggested by you in sometime. Would update with the results.

  4. This blog aims at clarifying the issues which 32-bit developers might be having when they start migrating…

Skip to main content