Search code examples
assemblysparcrisc

sparc assembly - add and addcc


I have just read some old courses on SPARC Assembly and I don't remember the difference between "add" and "addcc" instructions (like also sub and subcc).

Could you explain to me this difference ?

Thanks


Solution

  • The cc suffix indicates that the instruction sets the condition codes (Z, N, V flags). So add performs addition without setting the condition codes, while addcc performas addition and sets the condition codes.