compiler.cfg.instructions: ##bit-count insn

db4
Joe Groff 2010-05-15 13:57:35 -07:00
parent 7c6c4ef8ae
commit 7fec53b509
4 changed files with 7 additions and 0 deletions

View File

@ -219,6 +219,10 @@ PURE-INSN: ##log2
def: dst/int-rep
use: src/int-rep ;
PURE-INSN: ##bit-count
def: dst/int-rep
use: src/int-rep ;
! Float arithmetic
PURE-INSN: ##add-float
def: dst/double-rep

View File

@ -162,6 +162,7 @@ CODEGEN: ##max %max
CODEGEN: ##not %not
CODEGEN: ##neg %neg
CODEGEN: ##log2 %log2
CODEGEN: ##bit-count %bit-count
CODEGEN: ##copy %copy
CODEGEN: ##tagged>integer %tagged>integer
CODEGEN: ##add-float %add-float

View File

@ -270,6 +270,7 @@ HOOK: %max cpu ( dst src1 src2 -- )
HOOK: %not cpu ( dst src -- )
HOOK: %neg cpu ( dst src -- )
HOOK: %log2 cpu ( dst src -- )
HOOK: %bit-count cpu ( dst src -- )
HOOK: %copy cpu ( dst src rep -- )

View File

@ -164,6 +164,7 @@ M: x86 %max int-rep two-operand [ CMP ] [ CMOVL ] 2bi ;
M: x86 %not int-rep one-operand NOT ;
M: x86 %neg int-rep one-operand NEG ;
M: x86 %log2 BSR ;
M: x86 %bit-count POPCNT ;
! A bit of logic to avoid using MOVSS/MOVSD for reg-reg moves
! since this induces partial register stalls