Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7624727
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T05:02:28+00:00 2026-05-31T05:02:28+00:00

I am programming C on linux, and which is faster in the following conditions?

  • 0

I am programming C on linux, and which is faster in the following conditions?

1.processing 32bit integers on 32bit hardware and 64bit hardware

2.processing 64bit integers on 32bit hardware and 64bit hardware

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T05:02:29+00:00Added an answer on May 31, 2026 at 5:02 am

    You should tell on what exact hardware, and what kind of processing.

    And more importantly, you should benchmark your application, taking into account that premature optimization is evil.

    Standard C99 provides you with the <stdint.h> with the fastint_t type (and others, e.G. intptr_t or int32_t…); there is also a <inttypes.h> standard header.

    I believe you should not bother at first. If you know that some integer data type is very crucial to your application, you might use your own typedef, eg.

    typedef intfast_t myimportantint_t;
    

    Then you develop your application using appropriately myimportantint_t, and benchmark it. You can then easily change that typedef. (So changing the size of your important integers would be easy, just changing that typedef and perhaps defining a MYIMPORTANT_MAX preprocessor constant, etc.).

    See this question very related to yours.

    I believe you should not care that much.

    Of course, 64 bits arithmetic on many 32 bits processors is more costly than 32 bits arithmetic.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there any good parallel Mixed-Integer Programming optimizer which can run on the Linux?
New to Linux programming in general. I am trying to communicate with a kernel
i am new in programming under linux and trying to get working this code:
I'm pretty new to programming for Linux environments, so I don't exactly know what
I'm quite fond of using GNU getopt , when programming under Linux . I
I want to expand my programming horizons to Linux. A good, dependable basic toolset
Here is a challenge question I've got from Linux system programming lecture. Any of
I've been programming in C and C++ in Linux for around 3 years, and
OS: Linux, Language: pure C I'm moving forward in learning C programming in general,
Please explain from Linux, Windows perspectives? I am programming in C#, would these two

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.