inn on ncg now passes the CPU tests.

This commit is contained in:
David Given 2016-11-20 19:35:34 +01:00
parent 2d0bc7ef0d
commit f8fa3ece42

View file

@ -328,6 +328,7 @@ INSTRUCTIONS
lhax GPR:wo, GPR:ro, GPR:ro cost(4, 3). lhax GPR:wo, GPR:ro, GPR:ro cost(4, 3).
lhz GPR:wo, GPRINDIRECT:ro cost(4, 3). lhz GPR:wo, GPRINDIRECT:ro cost(4, 3).
lhzx GPR:wo, GPR:ro, GPR:ro cost(4, 3). lhzx GPR:wo, GPR:ro, GPR:ro cost(4, 3).
li32 GPR:wo, CONST:ro cost(8, 2).
li32 GPR:wo, LABEL:ro cost(8, 2). li32 GPR:wo, LABEL:ro cost(8, 2).
lwzu GPR:wo, GPRINDIRECT:ro cost(4, 3). lwzu GPR:wo, GPRINDIRECT:ro cost(4, 3).
lwzx GPR:wo, GPR:ro, GPR:ro cost(4, 3). lwzx GPR:wo, GPR:ro, GPR:ro cost(4, 3).
@ -1637,14 +1638,13 @@ PATTERNS
gen gen
bl {LABEL, ".set"} bl {LABEL, ".set"}
pat inn defined($1) /* Test for set bit */ pat inn /* Test for set bit */
leaving with STACK
set INT32 kills ALL
and INT32 uses REG
pat inn !defined($1) /* Test for set bit (variable) */
with GPR3 STACK
gen gen
li32 %a, {CONST, $1}
stwu %a, {GPRINDIRECT, SP, 0-4}
bl {LABEL, ".inn"} bl {LABEL, ".inn"}