瀏覽代碼

* Xtensa: make use of extui for shifting with constant values >=16

git-svn-id: trunk@44856 -
florian 5 年之前
父節點
當前提交
14d46bccba
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      compiler/xtensa/cgcpu.pas

+ 2 - 0
compiler/xtensa/cgcpu.pas

@@ -517,6 +517,8 @@ implementation
           list.concat(taicpu.op_reg_reg_const(A_SLLI,dst,src,a))
           list.concat(taicpu.op_reg_reg_const(A_SLLI,dst,src,a))
         else if (op=OP_SHR) and (a>=0) and (a<=15) then
         else if (op=OP_SHR) and (a>=0) and (a<=15) then
           list.concat(taicpu.op_reg_reg_const(A_SRLI,dst,src,a))
           list.concat(taicpu.op_reg_reg_const(A_SRLI,dst,src,a))
+        else if (op=OP_SHR) and (a>15) and (a<=31) then
+          list.concat(taicpu.op_reg_reg_const_const(A_EXTUI,dst,src,a,32-a))
         else
         else
           begin
           begin
             tmpreg:=getintregister(list,size);
             tmpreg:=getintregister(list,size);