You are currently viewing our boards as a guest, which gives you limited access to view most discussions and access our other features. By joining our free community, you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content, and access many other special features. Registration is fast, simple, and absolutely free, so please, <a href="/profile.php?mode=register">join our community today</a>!
I have a program that uses ints, but the numbers are guaranteed to be very, very small numbers (in the range of 0-3 or 0-19 or something like that)
Would changing around this program to use bytes and bitwise operators instead of ints and integer operators result in a performance increase? When the program runs for a long time, it uses a lot of memory. I imagine with smaller data types and "simpler" operations, the performance increase would be noticeable/significant. The program is only a few hundred lines of code, and looking at different ways of speeding things up in software, before we try porting to hardware. We're looking at using x86 and/or x86-64, as those are the systems most available to us.
If you move to bytes and if your algorithm has lots of parallelism you should see large speed ups over ints (4x). Even without packed SSE you still may see gains due to reduced cache pressure. It is it only .4K it shouldn't be that hard to try the quick conversion of the scalar path.
Ok, thanks plenty. This is going to be an exercise for me in tweaking code to make use of inherent CPU parallelism and probably some vector operations.
Users browsing this forum: No registered users and 1 guest
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum