[LLVMbugs] [Bug 11142] Testcase: suboptimal code in memory transportation

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Oct 18 02:29:06 PDT 2011


Nick Lewycky <nicholas at mxc.ca> changed:

           What    |Removed                     |Added
             Status|REOPENED                    |RESOLVED
         Resolution|                            |FIXED

--- Comment #10 from Nick Lewycky <nicholas at mxc.ca> 2011-10-18 04:29:05 CDT ---
That's a completely different problem: your new testcase doesn't have
targetdata in it. If I add the targetdata line from your previous test:

  target datalayout =

and run it through opt -O2, we eliminate all but two memcpy's, both copying
directly from their globals @label369 and @label374.

We can't do better than that (eliminate the malloc+memcpy+free) because that
string is passed into @fwrite, and it's entirely possible that fwrite does
something like look at the address of the pointer it's given.

Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

More information about the llvm-bugs mailing list