diff options
author | Sverker Eriksson <[email protected]> | 2017-03-22 21:39:48 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2017-03-22 21:39:48 +0100 |
commit | c5e09d9315044bb9ac27702f6a9d3c6f290a3b8e (patch) | |
tree | a9549285fa68b47d24ac8610d0daa0e2d64681d0 /lib/hipe/sparc/hipe_sparc_ra_finalise.erl | |
parent | b4ac8b2b32f094217d0533ee139273923c3a8af7 (diff) | |
parent | 9e618caac607379e1154e24bc9bd09709cce5d41 (diff) | |
download | otp-c5e09d9315044bb9ac27702f6a9d3c6f290a3b8e.tar.gz otp-c5e09d9315044bb9ac27702f6a9d3c6f290a3b8e.tar.bz2 otp-c5e09d9315044bb9ac27702f6a9d3c6f290a3b8e.zip |
Merge margnus1/hipe-range-split-rebase/PR-1380/OTP-14293
HiPE: Range splitting register allocation
Diffstat (limited to 'lib/hipe/sparc/hipe_sparc_ra_finalise.erl')
-rw-r--r-- | lib/hipe/sparc/hipe_sparc_ra_finalise.erl | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/hipe/sparc/hipe_sparc_ra_finalise.erl b/lib/hipe/sparc/hipe_sparc_ra_finalise.erl index 5fdb73e197..a724821992 100644 --- a/lib/hipe/sparc/hipe_sparc_ra_finalise.erl +++ b/lib/hipe/sparc/hipe_sparc_ra_finalise.erl @@ -38,6 +38,7 @@ ra_insn(I, Map, FPMap) -> #pseudo_call{} -> ra_pseudo_call(I, Map); #pseudo_move{} -> ra_pseudo_move(I, Map); #pseudo_set{} -> ra_pseudo_set(I, Map); + #pseudo_spill_move{} -> ra_pseudo_spill_move(I, Map); #pseudo_tailcall{} -> ra_pseudo_tailcall(I, Map); #rdy{} -> ra_rdy(I, Map); #sethi{} -> ra_sethi(I, Map); @@ -47,6 +48,7 @@ ra_insn(I, Map, FPMap) -> #pseudo_fload{} -> ra_pseudo_fload(I, Map, FPMap); #pseudo_fmove{} -> ra_pseudo_fmove(I, FPMap); #pseudo_fstore{} -> ra_pseudo_fstore(I, Map, FPMap); + #pseudo_spill_fmove{} -> ra_pseudo_spill_fmove(I, FPMap); _ -> I end. @@ -80,6 +82,12 @@ ra_pseudo_set(I=#pseudo_set{dst=Dst}, Map) -> NewDst = ra_temp(Dst, Map), I#pseudo_set{dst=NewDst}. +ra_pseudo_spill_move(I=#pseudo_spill_move{src=Src,temp=Temp,dst=Dst}, Map) -> + NewSrc = ra_temp(Src, Map), + NewTemp = ra_temp(Temp, Map), + NewDst = ra_temp(Dst, Map), + I#pseudo_spill_move{src=NewSrc,temp=NewTemp,dst=NewDst}. + ra_pseudo_tailcall(I=#pseudo_tailcall{funv=FunV,stkargs=StkArgs}, Map) -> NewFunV = ra_funv(FunV, Map), NewStkArgs = ra_args(StkArgs, Map), @@ -120,6 +128,13 @@ ra_pseudo_fmove(I=#pseudo_fmove{src=Src,dst=Dst}, FPMap) -> NewDst = ra_temp_fp(Dst, FPMap), I#pseudo_fmove{src=NewSrc,dst=NewDst}. +ra_pseudo_spill_fmove(I=#pseudo_spill_fmove{src=Src,temp=Temp,dst=Dst}, + FPMap) -> + NewSrc = ra_temp_fp(Src, FPMap), + NewTemp = ra_temp_fp(Temp, FPMap), + NewDst = ra_temp_fp(Dst, FPMap), + I#pseudo_spill_fmove{src=NewSrc,temp=NewTemp,dst=NewDst}. + ra_pseudo_fstore(I=#pseudo_fstore{src=Src,base=Base}, Map, FPMap) -> NewSrc = ra_temp_fp(Src, FPMap), NewBase = ra_temp(Base, Map), |