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

[Bug tree-optimization/57742] memset(malloc(n),0,n) -> calloc(n,1)


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=57742

--- Comment #20 from Marc Glisse <glisse at gcc dot gnu.org> ---
(In reply to Joost VandeVondele from comment #18)
> The following now fails, so'll reopen this PR. It is at least related to
> zeroing pvec twice in a row, and doesn seem to happen if I manually inline
> the routine get_pseudo_param .

Hum, right, I thought I had tested that, but it was in an earlier version of
the patch and I forgot to add it to one of the testcases :-(

void*f(){
  char*p=malloc(42);
  memset(p,0,42);
  memset(p,0,42);
  return p;
};


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