Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
10/21/02 18:56
Read: times


 
#31165 - RE: best ways to bit operation in keil C
Hi Maziar,

I don't use the Keil compiler but this is what I do.

For testing:

if (var & (1<<BIT))
...;

For inverting:

var ^= (1<<BIT);

You can try these and check out the generated assembler to see how efficient they are using Keil.

Dennis

List of 11 messages in thread
TopicAuthorDate
best ways to bit operation in keil C            01/01/70 00:00      
RE: best ways to bit operation in keil C            01/01/70 00:00      
RE: best ways to bit operation in keil C            01/01/70 00:00      
RE: best ways to bit operation in keil C            01/01/70 00:00      
RE: best ways to bit operation in keil C            01/01/70 00:00      
RE: best ways to bit operation to andy            01/01/70 00:00      
RE: best ways to bit operation in keil C            01/01/70 00:00      
RE: best ways to bit operation to andy            01/01/70 00:00      
RE: best ways to bit operation in keil C            01/01/70 00:00      
RE: best ways to bit operation in keil C            01/01/70 00:00      
RE: best ways to bit operation in keil C            01/01/70 00:00      

Back to Subject List