the avrgcc user manual recommends against using them, favouring bit operators
how come?
I think the confusion comes about because if you, ages ago..., wrote:
PORTD |= (1<<4);
Then the C compiler would generate 3 instructions:
1. Read PORTD
2. Set the bit
3. Write the answer to PORTD
But the AVR is capable of doing it one instruction which is actually called 'sbi' or 'cbi' to Set or 'Clear' a bit.
Hence I believe the original sbi and cbi macros were written to generate the single instruction by temporarily flicking into assembly language.
However: the C compiler has now been optimised so that rather than generating the 3 instructions above it only generates the one. So now the cbi and sbi macros are sort of defunct. I say 'sort of' in that they used to make your program smaller/better but now they don't make any difference.
ie
sbi(PORTD, 4);
and
PORTD |= (1<<4);
will actually generate the same code.
So they no longer effect the program - but I believe that they are more 'human readable' - so I continue to use them