This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [PATCH] Handle weak symbols


On Thu, May 10, 2001 at 12:42:43AM +0200, Franz Sirl wrote:
>   /* A and B may not be modified in the range [cond_earliest, jump).  */
>   for (insn = if_info.cond_earliest; insn != jump; insn = NEXT_INSN (insn))
>     if (INSN_P (insn)
>         && (modified_in_p (a, insn) || modified_in_p (b, insn)))
>       return FALSE;
> 
> The use of modified_in_p rejects any MEMs.

Hum.  Perhaps that could be fixed, but:

> Even if I disable this code the 
> store-flag optimizations no longer handle code like this anymore:
[...]
> (jump_insn 15 14 45 (set (pc)
>         (if_then_else (eq (reg:CC 87)
>                 (const_int 0 [0x0]))
>             (label_ref 25)
>             (pc))) 464 {*rs6000.md:12535} (insn_list 14 (nil))
>     (expr_list:REG_DEAD (reg:CC 87)
>         (expr_list:REG_BR_PROB (const_int 3999 [0xf9f])
>             (nil))))
> 
> (insn 19 45 20 (set (reg:SI 84)
>         (mem/f:SI (lo_sum:SI (reg/f:SI 86)
>                 (symbol_ref:SI ("@__dso_handle"))) 3)) 286 {*movsi_internal1} 
> (nil)
>     (expr_list:REG_DEAD (reg/f:SI 86)
>         (nil)))

Well?  What exactly do you want done?  There's no conditional load
on powerpc.  Or are you suggesting this might be doable because the
address is supposed to be non-trapping?  I didn't think yall had
conditional moves either though...

> Nevertheless, I still think we should bring in at least a minimum patch into 
> the branch, introducing SYMBOL_REF_WEAK, set it  in make_decl_rtl, and 
> evaluate it in rtx_addr_can_trap_p. I  don't want to get bitten by that 
> problem again and rtx_addr_can_trap_p is such a central routine that I don't 
> feel comfortable if we don't do something about it for 3.0.

Frankly, I agree.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]