[PATCH] D59477: [RISCV] Custom lower SHL_PARTS, SRA_PARTS, SRL_PARTS

Alex Bradbury via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 17 22:39:28 PDT 2019


asb requested changes to this revision.
asb added a comment.
This revision now requires changes to proceed.

Thanks for this Luis. This needs coverage for the optForMinSize checks. I'd recommend extending shifts.ll with minsize versions of the tests, e.g.

  define i64 @lshr64_minsize(i64 %a, i64 %b) minsize nounwind {                             
  ; RV32I-LABEL: lshr64_minsize:                                                            
  ; RV32I:       # %bb.0:                                                                   
  ; RV32I-NEXT:    addi sp, sp, -16                                                         
  ; RV32I-NEXT:    sw ra, 12(sp)                                                            
  ; RV32I-NEXT:    call __lshrdi3                                                           
  ; RV32I-NEXT:    lw ra, 12(sp)                                                            
  ; RV32I-NEXT:    addi sp, sp, 16                                                          
  ; RV32I-NEXT:    ret                                                                      
    %1 = lshr i64 %a, %b                                                                    
    ret i64 %1                                                                              
  }   


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59477/new/

https://reviews.llvm.org/D59477





More information about the llvm-commits mailing list