Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with Facebook Sign In with Google Sign In with OpenID

Categories

We have migrated to a new platform! Please note that you will need to reset your password to log in (your credentials are still in-tact though). Please contact lee@programmersheaven.com if you have questions.
Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Double types are faster than integer types?!!

hadipardishadipardis Posts: 134Member
I have a heavy loop in which many mathematical operations must be done. In my experiments I saw that working with double types are very faster than woking with integer and extended types or even byte types.But I don't know its reason? Do you know? Thanks

Comments

  • zibadianzibadian Posts: 6,349Member
    : I have a heavy loop in which many mathematical operations must be done. In my experiments I saw that working with double types are very faster than woking with integer and extended types or even byte types.But I don't know its reason? Do you know? Thanks
    :
    That's weird, since integers operations are faster than floating-point operations. But it might be that your integer calculation code wasn't fully optimized or that the CPU was busy with other processes during your test run, and thus the program didn't receive as many cycles as the run of the double calculations.
Sign In or Register to comment.