Mercurial > hg > index.cgi
diff lwasm/cycle.c @ 405:4c8925f97eb5
Fix bug identifying long branches in cycle counting code
Long branch opcodes start at 0x1022 for conditional branches, not 0x1023.
author | William Astle <lost@l-w.ca> |
---|---|
date | Thu, 03 Mar 2016 20:52:15 -0700 |
parents | 4fd16faa4d93 |
children | 0af33282b518 |
line wrap: on
line diff
--- a/lwasm/cycle.c Thu Oct 15 23:21:26 2015 -0600 +++ b/lwasm/cycle.c Thu Mar 03 20:52:15 2016 -0700 @@ -659,7 +659,7 @@ cl->cycle_adj = 0; // long branches are estimated on 6809 - if (CURPRAGMA(cl, PRAGMA_6809) && (opc >= 0x1023 && opc <= 0x102f)) + if (CURPRAGMA(cl, PRAGMA_6809) && (opc >= 0x1022 && opc <= 0x102f)) cl->cycle_flags |= CYCLE_ESTIMATED; return;