Re: [PATCH 06/16] Introduce emit_status::ensure_regno_capacity

2016-10-05 Thread Bernd Schmidt
On 10/05/2016 06:15 PM, David Malcolm wrote: - regno_reg_rtx = ggc_vec_alloc (crtl->emit.regno_pointer_align_length); + regno_reg_rtx = +ggc_cleared_vec_alloc (crtl->emit.regno_pointer_align_length); Oops, also: formatting, operators go first on a newline. Bernd

Re: [PATCH 06/16] Introduce emit_status::ensure_regno_capacity

2016-10-05 Thread Bernd Schmidt
On 10/05/2016 06:15 PM, David Malcolm wrote: - /* Make sure regno_pointer_align, and regno_reg_rtx are large - enough to have an element for this pseudo reg number. */ + int cur_size = crtl->emit.regno_pointer_align_length; + if (reg_rtx_no == cur_size) +

[PATCH 06/16] Introduce emit_status::ensure_regno_capacity

2016-10-05 Thread David Malcolm
gcc/ChangeLog: * emit-rtl.c (gen_reg_rtx): Move regno_pointer_align and regno_reg_rtx resizing logic to... (emit_status::ensure_regno_capacity): ...this new method. (init_emit): Allocate regno_reg_rtx using ggc_cleared_vec_alloc rather than ggc_vec_alloc.