Jump to content

  • Log In with Google      Sign In   
  • Create Account


Bitwise operators performance


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
1 reply to this topic

#1 lomateron   Members   -  Reputation: 281

Like
0Likes
Like

Posted 22 November 2012 - 06:20 AM

In HLSL I can write a multiplication,addition,etc in terms of bitwise operations.
What is faster?



Sponsor:

#2 Hodgman   Moderators   -  Reputation: 24004

Like
0Likes
Like

Posted 22 November 2012 - 06:32 AM

The compiler knows that integer * 2 == integer << 2. If one is faster than the other, the compiler can/will substitute.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS