In my code I use the nop instruction (for short delay). The compiler warns me:
warning: #174-D: expression has no effect
How can I suppress this warning?
When I searched for "intrinsic" I found I can use __nop(). This did not give me any warnings.
Exactly. Note that when you inline assembler, then the compiler will run the code optimizer over your assembler instructions too. And the compiler see no use for any nop instructions. They are just good-for-nothing no-operations that should be removed - they are as meaningful as an assign a=a.
With the intrinsic, the compiler will be much nicer and caring about your NOP instructions, making it realize that you explicitly want the time delay side effect, and at that specific position in the code.