#250 Use bit instruction instead of and in jump conditions

closed
z80 port (30)
2
2012-08-01
2008-03-17
No

For code like

if(foo & 0x40)

sdcc generates code that loads foo into the accumulator and ands it with 0x40.

It would be more efficient to use the bit instruction to do the test since it saves the moving of foo into a.

Philipp

Discussion

  • Philipp Klaus Krause

    • labels: --> z80 port
     
  • Philipp Klaus Krause

    • priority: 5 --> 2
     
  • Philipp Klaus Krause

    Reducing priority sine this is about a very minor improvement in code size and speed.

     
  • Philipp Klaus Krause

    This has been implemented around the same time as #3526286 in the smallopts branch.

    Philipp

     
  • Philipp Klaus Krause

    • status: open --> closed
     
  • Philipp Klaus Krause

    Implemented by merging the smallopts branch about two weeks ago.

    Philipp

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks