Re: [PATCH 3/3] spill-reload: Use radix_tree_lookup() in insert_mov_insns()

2009-08-18 Thread Arthur Huillet
Ack here as well, this is obviously correct (provided radix_tree_lookup() works). On Tue, 18 Aug 2009 21:41:19 +0300 Pekka Enberg penb...@cs.helsinki.fi wrote: Lets use radix_tree_lookup() and get rid of the nasty loop in bb_last_insn(). For some reason, this seems to fix the infinite loop

[PATCH 2/3] spill-reload: Remove redundant argument from insert_copy_slot_insn()

2009-08-18 Thread Pekka Enberg
The 'pop_at_insn' argument is not used in insert_copy_slot_insn() function so remove it to clean up code. Cc: Arthur HUILLET arthur.huil...@free.fr Cc: Tomek Grabiec tgrab...@gmail.com Signed-off-by: Pekka Enberg penb...@cs.helsinki.fi --- jit/spill-reload.c | 13 + 1 files

[PATCH 3/3] spill-reload: Use radix_tree_lookup() in insert_mov_insns()

2009-08-18 Thread Pekka Enberg
Lets use radix_tree_lookup() and get rid of the nasty loop in bb_last_insn(). For some reason, this seems to fix the infinite loop triggered by empty basic blocks. Cc: Arthur HUILLET arthur.huil...@free.fr Cc: Tomek Grabiec tgrab...@gmail.com Signed-off-by: Pekka Enberg penb...@cs.helsinki.fi ---

[PATCH 1/3] spill-reload: Insert spill instructions before branches

2009-08-18 Thread Pekka Enberg
Use insn_is_branch() to determine whether we must insert a spill instruction before or after the last instruction in a basic block. Cc: Arthur HUILLET arthur.huil...@free.fr Cc: Tomek Grabiec tgrab...@gmail.com Signed-off-by: Pekka Enberg penb...@cs.helsinki.fi ---

Re: [PATCH 3/3] spill-reload: Use radix_tree_lookup() in insert_mov_insns()

2009-08-18 Thread Tomek Grabiec
2009/8/18 Pekka Enberg penb...@cs.helsinki.fi: Lets use radix_tree_lookup() and get rid of the nasty loop in bb_last_insn(). For some reason, this seems to fix the infinite loop triggered by empty basic blocks. Cc: Arthur HUILLET arthur.huil...@free.fr Cc: Tomek Grabiec tgrab...@gmail.com

Re: [PATCH 3/3] spill-reload: Use radix_tree_lookup() in insert_mov_insns()

2009-08-18 Thread Pekka Enberg
On Tue, 2009-08-18 at 21:21 +0200, Tomek Grabiec wrote: Like I said on IRC, this will not work for empty basic blocks, because spill_at_insn will belong to the preceding basic block. This causes that instructions will be added to different (preceding) basic block and might not be executed on