Work on atomic counters.

opcodes: imm_atomic_alloc and imm_atomic_consume.
More work is needed for the binding and offset layout qualifiers on
atomic_uint counters.
Small code cleanup - combine some if statements.