https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122103

--- Comment #28 from liu zhenyu <lzy20000419 at outlook dot com> ---
(In reply to Richard Biener from comment #27)
> There's definitely a gap in gimple_could_trap_p_1 handling of calls.  Any
> builtin is handled as
> 
>             tree type = TREE_TYPE (gimple_call_fntype (s));
>             bool fp_operation = FLOAT_TYPE_P (type);
>             return fp_operation && flag_trapping_math;
> 
> so the float-to-integer builtins can be handled explicitly.  But then any
> call to a regular function is also classified as not trapping which is
> of course not true either (but usually harmless unless the function is
> also const or pure in which case it's unspecified whether setting IEEE
> flags would be considered making const/pure an invalid specification).
> 
> It might be good to raise this in a separate bug.

Filed separately as PR128237.

Reply via email to