From 85bd166647e7f260fd665eb44da9151c0d88f208 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Magnus=20L=C3=A5ng?= Date: Sat, 28 May 2016 20:22:34 +0200 Subject: hipe: Add hipe_regalloc_prepass hipe_regalloc_prepass speeds up register allocation by spilling any temp that is live over a call (which clobbers all register). In order to detect these, a new function was added to the target interface; defines_all_alloc/1, that takes an instruction and returns a boolean. --- lib/hipe/regalloc/hipe_arm_specific.erl | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib/hipe/regalloc/hipe_arm_specific.erl') diff --git a/lib/hipe/regalloc/hipe_arm_specific.erl b/lib/hipe/regalloc/hipe_arm_specific.erl index e04d80f690..c696668399 100644 --- a/lib/hipe/regalloc/hipe_arm_specific.erl +++ b/lib/hipe/regalloc/hipe_arm_specific.erl @@ -40,6 +40,7 @@ ,livein/2 ,uses/1 ,defines/1 + ,defines_all_alloc/1 ]). %% for hipe_graph_coloring_regalloc: @@ -129,6 +130,9 @@ defines(I) -> [X || X <- hipe_arm_defuse:insn_def_gpr(I), hipe_arm:temp_is_allocatable(X)]. +defines_all_alloc(I) -> + hipe_arm_defuse:insn_defs_all_gpr(I). + is_move(Instruction) -> case hipe_arm:is_pseudo_move(Instruction) of true -> -- cgit v1.2.3