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]

Re: Patch to allow strlen expander to fail



  In message <200003060159.e261xPj06505@sleipnir.valparaiso.cl>you write:
  > Jan Hubicka <hubicka@atrey.karlin.mff.cuni.cz> said on gcc-patches:
  > > This patch adds the strlen libcall and necesary code to emit_builtin_strl
  > en
  > > to emit libcall when strlen expander fails.
  > 
  > Is there some documentation about the functions gcc might generate calls
  > to? 
No, and any such documentation would have the caveat that the conditions
under which GCC will use a libcall can change without warning or
predictability.

Any code which depends on gcc generating or not generating libcalls is
broken.

  > There was recently a problem with the Linux kernel because gcc
  > willy-nilly called memcpy(3), and that one isn't around in the kernel,
Then that's a kernel problem.  They're depending on a specific, undocumented
and highly implementation dependent behavior in the compiler.  That's dumb.

jeff



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