Answer the question
In order to leave comments, you need to log in
When compiling under x32, __uint64_t-variables don't want to shift by 32 bits, what's wrong?
The variable is not shifted to values < 32, but when the shift is stronger, the value is reset to zero. In fact, the variable behaves like a 32-bit variable, but I declare it as unsigned long long int.
What is the reason for this behavior?
Answer the question
In order to leave comments, you need to log in
Here the problem is very tricky. both arguments must be 64bit.
For example:
__int64 a = 1ull << 33; // will work,
__int64 b = 1 << 33; // zero out
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question