This is the mail archive of the gcc-bugs@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]
Other format: [Raw text]

[Bug middle-end/67133] [6 Regression] ICE at -Os and above on x86_64-linux-gnu in gimple_op, at gimple.h:2274


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

--- Comment #26 from Martin Jambor <jamborm at gcc dot gnu.org> ---
If fntype specifies the ABI then when we know we will be calling a
different function (which might have its prototype modified for
example by parameter removal), then we should set the fntype too.  And
further inspection of cgraph_edge::redirect_call_stmt_to_callee also
suggests that is the correct thing.  Therefore I'll bootstrap the
patch from comment #20 and propose it on the mailing list.

While the committed patch does prevent the ICE, I would actually
prefer if gimple checking failed when it encounters a direct call with
mismatching fntype.  It can't happen because of this bug but I suppose
we might get wrong-code generation if we get the type only slightly
wrong.


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