On 12/3/12, Diego Novillo <dnovi...@google.com> wrote: > On 2012-12-01 20:48 , Lawrence Crowl wrote: >> +inline bool >> +cselib_hasher::equal (const value_type *v, const compare_type *x_arg) >> +{ >> + struct elt_loc_list *l; >> + rtx x = CONST_CAST_RTX (x_arg); >> + enum machine_mode mode = GET_MODE (x); >> + >> + gcc_assert (!CONST_SCALAR_INT_P (x) && GET_CODE (x) != CONST_FIXED); >> + >> + if (mode != GET_MODE (v->val_rtx)) >> + return 0; >> + >> + /* Unwrap X if necessary. */ >> + if (GET_CODE (x) == CONST >> + && (CONST_SCALAR_INT_P (XEXP (x, 0)) >> + || GET_CODE (XEXP (x, 0)) == CONST_FIXED)) >> + x = XEXP (x, 0); >> + >> + /* We don't guarantee that distinct rtx's have different hash values, >> + so we need to do a comparison. */ >> + for (l = v->locs; l; l = l->next) >> + if (rtx_equal_for_cselib_1 (l->loc, x, find_slot_memmode)) >> + { >> + promote_debug_loc (l); >> + return 1; >> + } >> + >> + return 0; > > s/1/true/ > s/0/false/
Done. >> @@ -504,8 +557,10 @@ cselib_get_next_uid (void) >> return next_uid; >> } >> >> +#if 0 >> /* See the documentation of cselib_find_slot below. */ >> static enum machine_mode find_slot_memmode; >> +#endif > > Remove? Done. >> +#if 0 >> /* The equality test for our hash table. The first argument ENTRY is a >> table >> element (i.e. a cselib_val), while the second arg X is an rtx. We >> know >> that all callers of htab_find_slot_with_hash will wrap CONST_INTs >> into a >> @@ -570,6 +626,7 @@ get_value_hash (const void *entry) >> const cselib_val *const v = (const cselib_val *) entry; >> return v->hash; >> } >> +#endif > > Remove? Done. > OK otherwise. > > This only leaves the GC htabs, right? No, there are still more non-GC htabs. > What was the issue there? gengtype being silly? Yes. -- Lawrence Crowl