On 11/9/2021 9:13 AM, Jan Hubicka via Gcc-patches wrote:
Hi,
since at the time we compute local solution during late modref the
summaries from IPA are readily available (and I added logic to compare
them), it is easy to intersect both solutions to get around cases
where late optimization obstructate code enough so flags are no longer
analyzed correctly.  This improves PTA disabiguation rage by about 0.5%

Bootstrapped/regtested x86_64-linux, comitted.
gcc/ChangeLog:

        * ipa-modref.c (analyze_parms): Add past_flags, past_retslot_flags
        and past_static_chain; merge past summary with current one.
        (analyze_function): Update.


@@ -2431,8 +2472,23 @@ analyze_parms (modref_summary *summary, 
modref_summary_lto *summary_lto,
    if (static_chain)
      {
        int flags = eaf_analysis.get_ssa_name_flags (static_chain);
+      int past = past_static_chain_flags;
flags = remove_useless_eaf_flags (flags, ecf_flags, false);
+      past = remove_useless_eaf_flags
+                (past, ecf_flags,
+                 VOID_TYPE_P (TREE_TYPE
+                     (TREE_TYPE (current_function_decl))));
+      if (dump_file && (flags | past) != flags && !(flags & EAF_UNUSED))
+       {
+         fprintf (dump_file,
+                  "  Static chain flags combined with IPA pass:");
+         dump_eaf_flags (dump_file, past, false);
+         fprintf (dump_file, " local ");
+         dump_eaf_flags (dump_file, flags, true);
+       }
+      if (!(flags & EAF_UNUSED))
+       lags |= past;
                   ^^^^^


Broke bootstrap.

jeff

Reply via email to