public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Dominance information problem
@ 2020-09-12  7:26 Gary Oblock
  2020-09-14  7:10 ` Erick Ochoa
  0 siblings, 1 reply; 3+ messages in thread
From: Gary Oblock @ 2020-09-12  7:26 UTC (permalink / raw)
  To: gcc

I'm trying to do performance qualification for my structure
reorganization optimization.

I'm doing pretty straightforward stuff and I haven't at this point in
time (qualifying the optimization,) modified the program. So I'm a
little surprised this is failing.  Here is the code that's failing on
the first iteration of the for loops:

  struct cgraph_node *node;
  FOR_EACH_FUNCTION_WITH_GIMPLE_BODY ( node)  {
    struct function *func = DECL_STRUCT_FUNCTION ( node->decl);
    push_cfun ( func);

    class loop *loop;
    FOR_EACH_LOOP_FN ( func, loop, LI_ONLY_INNERMOST )
      {
        size_t num_bbs = loop->num_nodes;
        basic_block *bbs = get_loop_body ( loop); // FAILS HERE!!!
        :
        stuff never reached

How it's failing (in code from dominance.c) I'm guessing tells me the
dominance information is messed up (unlikely) or needs to be
recomputed. If I'm not wrong, how do I go about doing the later????

/* Return TRUE in case BB1 is dominated by BB2.  */
bool
dominated_by_p (enum cdi_direction dir, const_basic_block bb1, const_basic_block bb2)
{
  unsigned int dir_index = dom_convert_dir_to_idx (dir);
  struct et_node *n1 = bb1->dom[dir_index], *n2 = bb2->dom[dir_index];

  gcc_checking_assert (dom_computed[dir_index]); // <=========== BOOM!

  if (dom_computed[dir_index] == DOM_OK)
    return (n1->dfs_num_in >= n2->dfs_num_in
     && n1->dfs_num_out <= n2->dfs_num_out);

  return et_below (n1, n2);
}


Thanks,

Gary Oblock






CONFIDENTIALITY NOTICE: This e-mail message, including any attachments, is for the sole use of the intended recipient(s) and contains information that is confidential and proprietary to Ampere Computing or its subsidiaries. It is to be used solely for the purpose of furthering the parties' business relationship. Any unauthorized review, copying, or distribution of this email (or any attachments thereto) is strictly prohibited. If you are not the intended recipient, please contact the sender immediately and permanently delete the original and any copies of this email and any attachments thereto.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-09-14 18:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-12  7:26 Dominance information problem Gary Oblock
2020-09-14  7:10 ` Erick Ochoa
2020-09-14 18:20   ` Gary Oblock

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).