Shop OBEX P1 Docs P2 Docs Learn Events
Instruction Prefix EEEE -> Prefix condition PPPP ? — Parallax Forums

Instruction Prefix EEEE -> Prefix condition PPPP ?

I've never used the Propeller and I've been reading the P2 Documentation and Instructions (v18) for the first time today.

Getting rid of CCCC to avoid confusion with carry seems a good idea to me but EEEE doesn't suggest a condition that is prefixed.

Comments

  • cgraceycgracey Posts: 14,152
    TonyB wrote: »
    I've never used the Propeller and I've been reading the P2 Documentation and Instructions (v18) for the first time today.

    Getting rid of CCCC to avoid confusion with carry seems a good idea to me but EEEE doesn't suggest a condition that is prefixed.

    I agree, but what to call it, then?

    I used EEEE for 'execution condition'.
  • jmgjmg Posts: 15,173
    edited 2017-04-21 21:12
    Prefix operation is an Assembler design detail, not so much something embedded into the opcode.
    Using CCCC or EEEE or PPPP alerts that there are 4 bits in the field, but dos not try to identify individual bits.

    Another name could be COND, also 4 char/bits, but tag is now a real word, closer to assembler use.

    Whatever is used, is going to need some expansion explanation.
    I see Chip uses Instruction Prefix later in the Docs

    Adding a header tag to the encoding column may be enough ?
    EEEE = Instruction Prefix, see line 385..

    or

    COND = Conditional Instruction Prefix, see line 385..

    or

    PRFX = Conditional Instruction Prefix, see line 385..

    Choose the easiest to read/scan ?
  • PPPP = Prefix condition
    or simply
    PPPP = Prefix

    Putting the conditions are the start of the line will be strange at first for a lot of newcomers used to other microprocessors. Moving the bits formerly known as condition codes to the msb's helps reinforces the idea that they are prefixes. P for prefix ...
  • jmgjmg Posts: 15,173
    TonyB wrote: »
    PPPP = Prefix condition
    or simply
    PPPP = Prefix

    Putting the conditions are the start of the line will be strange at first for a lot of newcomers used to other microprocessors. Moving the bits formerly known as condition codes to the msb's helps reinforces the idea that they are prefixes. P for prefix ...

    Maybe, but the Conditional aspect is more important than the Prefix one, P alone makes it sound like some mandatory prefix ?
    Most assembler lines have no prefix at all (encoded by assembler with COND = 1111)

  • Lower case c for one / upper case C for the other?
  • cgraceycgracey Posts: 14,152
    Tubular wrote: »
    Lower case c for one / upper case C for the other?

    That's a good idea.
  • evanhevanh Posts: 15,915
    EEEE is good. It's perfectly clear after a quick check, no more repeated confusion. Much better than the Prop1 for sure. Leave it alone.
Sign In or Register to comment.