This is the mail archive of the gcc@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]

tree-ssa-dom.c Bug or not?


Just looking at the file mentioned in the subject I have found the
following suspicious code around line 1380:

static void
record_cond (tree cond, tree value)
{
  ...
  slot = htab_find_slot_with_hash (avail_exprs, (void *)element,
				   element->hash, true);
 ...
}

A one is passed in the form of true as the last argument to the
above function. However this arguments seems to be of enum inert_option type.
Checking the possible values of insert_option shows that the values
used there should read INSERT instead.


Thus we should have:

  slot = htab_find_slot_with_hash (avail_exprs, (void *)element,
				   element->hash, INSERT);

Instead there.

PS. I didn't prepare a patch, since applying such a patch would be more
difficult then just looking the code in question up and changing it directly
for someone with commit permissions anyway.



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