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]

Re: [patch] stmt.c: Speed/clean up expand_case - Part 2


Hi Richard,

> > Technically, could a backend define a __builtin_xxx and expands it to
> > a CONST_INT?
> 
> Yes, it could.  But I think I don't care.  If optimization is on,
> it'll get cleaned up later.  And the target does have the option
> of the fold_builtin target hook to make this happen earlier.

I'll submit a new patch that has both

  gcc_assert (TREE_CODE (index_expr) != INTEGER_CST);
  gcc_assert (GET_CODE (index) != CONST_INT);

as a friendly reminder to a backend. :-)

Kazu Hirata


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