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]
Other format: [Raw text]

[PATCH] Fix PR rtl-optimization/34999


Hello,

The code for fixing up fallthru edges that cross between hot and cold
sections is in add_labels_and_missing_jumps () and fix_up_fall_thru_edges
() functions.  The first function deals with fallthru edges with
single successor and the later deals with fallthru edges with more
than one successor.  Both of the functions do not take into account the
fact that a basic-block with a crossing edge can end with a call insn.
This patch tries to address this scenario.

The patch was bootstrapped and tested powerpc64-linux and x86_64.

OK for 4.4?

:ADDPATCH (rtl optimization):

Thanks,
Revital

        PR rtl-optimization/34999
        * bb-reorder.c (add_labels_and_missing_jumps): Do not handle
        crossing edges that ends with a call insn.
        (fix_up_fall_thru_edges): Handle crossing edges that ends with a
        call insn and clear the EDGE_CROSSING flag of the crossing edge
        when fixing fallthru edges.

testuite:

        PR rtl-optimization/34999
        * gcc.dg/tree-prof/pr34999.c: New.

(See attached file: pr34999.c.txt)(See attached file:
patch_31_fallthru.txt)

Attachment: pr34999.c.txt
Description: Text document

Attachment: patch_31_fallthru.txt
Description: Text document


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