3

Is there a code in the CPU12 processor that provides straightforward NOT functionality?

artless noise
  • 21,212
  • 6
  • 68
  • 105
  • Logical NOT is not a common microprocessor feature. I suppose it could exist on some processor, but not any those that I've ever worked with. – Jim Mischel Sep 30 '12 at 22:11
  • Jim, on a MIPS processor, there is a way to do this: slti dest_reg, src_reg, 1 is exactly equivalent to a logical not. 0 becomes 1 and all non-zero values become 0. – gary Nov 12 '12 at 12:37

2 Answers2

1

This should be the datasheet you're looking for. There is no logical NOT available, you'll have to code it yourself.

Freescale-CPU12-datasheet

Avio
  • 2,700
  • 6
  • 30
  • 50
0

COM, COMA and COMB look like they do what you're looking for; they calculate the one's complement for a memory location, the A or the B register, respectively.

Omaha
  • 2,262
  • 15
  • 18