This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Article on mixing 'C' and assembler (ARM focussed, but largely generic)

Here's a good paper from ARM TechCon about mixing assembler with High-Level Languages (HLLs) such as C and C++

very dangerous in the hands of a novice."

It seems to me that the vast majority of questions about inline assembler on this (and other) forums are from novices - and, thus, are generally bad ideas.

The article outlines 3 ways to access assembler functionality, in order of preference:

1. First, use Compiler Intrinsics wherever possible;

2. Use separate assembler source files, with functions to be called from the HLL;

3. As a last resort, and only for experienced developers, use inline assembler.

These principles would equally apply to C51 - and any other compiler...