History log of /external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
365ef0b197d7c841f8e501da64296df65be4ca23 03-Jul-2013 Craig Topper <craig.topper@gmail.com> Use SmallVectorImpl::iterator/const_iterator instead of SmallVector to avoid specifying the vector size.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185540 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
9792b646c68d0dcee4049662091f1496b4c85ce7 08-Jun-2013 Shuxin Yang <shuxin.llvm@gmail.com> Fix a potential bug in r183584.

r183584 tries to derive some info from the code *AFTER* a call and apply
these derived info to the code *BEFORE* the call, which is not always safe
as the call in question may never return, and in this case, the derived
info is invalid.

Thank Duncan for pointing out this potential bug.

rdar://14073661


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@183606 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
1c2b03aae9e56e69d215e9b39928a1340e3ca0c3 08-Jun-2013 Shuxin Yang <shuxin.llvm@gmail.com> Fix an assertion in MemCpyOpt pass.

The MemCpyOpt pass is capable of optimizing:
callee(&S); copy N bytes from S to D.
into:
callee(&D);
subject to some legality constraints.

Assertion is triggered when the compiler tries to evalute "sizeof(typeof(D))",
while D is an opaque-typed, 'sret' formal argument of function being compiled.
i.e. the signature of the func being compiled is something like this:
T caller(...,%opaque* noalias nocapture sret %D, ...)

The fix is that when come across such situation, instead of calling some
utility functions to get the size of D's type (which will crash), we simply
assume D has at least N bytes as implified by the copy-instruction.

rdar://14073661


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@183584 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
0b8c9a80f20772c3793201ab5b251d3520b9cea3 02-Jan-2013 Chandler Carruth <chandlerc@gmail.com> Move all of the header files which are involved in modelling the LLVM IR
into their new header subdirectory: include/llvm/IR. This matches the
directory structure of lib, and begins to correct a long standing point
of file layout clutter in LLVM.

There are still more header files to move here, but I wanted to handle
them in separate commits to make tracking what files make sense at each
layer easier.

The only really questionable files here are the target intrinsic
tablegen files. But that's a battle I'd rather not fight today.

I've updated both CMake and Makefile build systems (I think, and my
tests think, but I may have missed something).

I've also re-sorted the includes throughout the project. I'll be
committing updates to Clang, DragonEgg, and Polly momentarily.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171366 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
d04a8d4b33ff316ca4cf961e06c9e312eff8e64f 03-Dec-2012 Chandler Carruth <chandlerc@gmail.com> Use the new script to sort the includes of every file under lib.

Sooooo many of these had incorrect or strange main module includes.
I have manually inspected all of these, and fixed the main module
include to be the nearest plausible thing I could find. If you own or
care about any of these source files, I encourage you to take some time
and check that these edits were sensible. I can't have broken anything
(I strictly added headers, and reordered them, never removed), but they
may not be the headers you'd really like to identify as containing the
API being implemented.

Many forward declarations and missing includes were added to a header
files to allow them to parse cleanly when included first. The main
module rule does in fact have its merits. =]

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169131 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
426c2bf5cdd2173e4a33aea8cb92cf684a724f4b 01-Nov-2012 Chandler Carruth <chandlerc@gmail.com> Revert the majority of the next patch in the address space series:

r165941: Resubmit the changes to llvm core to update the functions to
support different pointer sizes on a per address space basis.

Despite this commit log, this change primarily changed stuff outside of
VMCore, and those changes do not carry any tests for correctness (or
even plausibility), and we have consistently found questionable or flat
out incorrect cases in these changes. Most of them are probably correct,
but we need to devise a system that makes it more clear when we have
handled the address space concerns correctly, and ideally each pass that
gets updated would receive an accompanying test case that exercises that
pass specificaly w.r.t. alternate address spaces.

However, from this commit, I have retained the new C API entry points.
Those were an orthogonal change that probably should have been split
apart, but they seem entirely good.

In several places the changes were very obvious cleanups with no actual
multiple address space code added; these I have not reverted when
I spotted them.

In a few other places there were merge conflicts due to a cleaner
solution being implemented later, often not using address spaces at all.
In those cases, I've preserved the new code which isn't address space
dependent.

This is part of my ongoing effort to clean out the partial address space
code which carries high risk and low test coverage, and not likely to be
finished before the 3.2 release looms closer. Duncan and I would both
like to see the above issues addressed before we return to these
changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167222 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
2c39b15073db81d93bb629303915b7d7e5d088dc 15-Oct-2012 Micah Villmow <villmow@gmail.com> Resubmit the changes to llvm core to update the functions to support different pointer sizes on a per address space basis.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165941 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
fb384d61c78b60787ed65475d8403aee65023962 11-Oct-2012 Micah Villmow <villmow@gmail.com> Revert 165732 for further review.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165747 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
f3840d2c16a4ec4c879a8ded402835746de380f8 11-Oct-2012 Micah Villmow <villmow@gmail.com> Add in the first iteration of support for llvm/clang/lldb to allow variable per address space pointer sizes to be optimized correctly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165726 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
3574eca1b02600bac4e625297f4ecf745f4c4f32 08-Oct-2012 Micah Villmow <villmow@gmail.com> Move TargetData to DataLayout.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165402 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
3372c5a50fba4e4d277ba627a6b711e3df5f493d 05-Oct-2012 Duncan Sands <baldrick@free.fr> Move this test a bit later, after the point at which we know that we either
have an alloca or a parameter, since then the alloca test should make sense
to readers, while before it probably appears too specific. No functionality
change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165306 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
7508f946bc4b5022cc4612c8c7492f2e23043976 04-Oct-2012 Duncan Sands <baldrick@free.fr> In my recent change to avoid use of underaligned memory I didn't notice that
cpyDest can be mutated in some cases, which would then cause a crash later if
indeed the memory was underaligned. This brought down several buildbots, so
I guess the underaligned case is much more common than I thought!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165228 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
f58747517cf2ba55c6f89a5ddc4de63be9e1362f 04-Oct-2012 Duncan Sands <baldrick@free.fr> The memcpy optimizer was happily doing call slot forwarding when the new memory
was less aligned than the old. In the testcase this results in an overaligned
memset: the memset alignment was correct for the original memory but is too much
for the new memory. Fix this by either increasing the alignment of the new
memory or bailing out if that isn't possible. Should fix the gcc-4.7 self-host
buildbot failure.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165220 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
39acdb0200ff78065699509fccfc605f86237350 13-Sep-2012 Benjamin Kramer <benny.kra@googlemail.com> MemCpyOpt: When forming a memset from stores also take GEP constexprs into account.

This is common when storing to global variables.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@163809 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a94d6e87c4c49f2e81b01d66d8bfb591277f8f96 24-Jul-2012 Nadav Rotem <nadav.rotem@intel.com> Clean whitespaces.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160668 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
06cb8ed00696eb14d1b831921452e50ec0568ea2 29-Jun-2012 Chandler Carruth <chandlerc@gmail.com> Move llvm/Support/IRBuilder.h -> llvm/IRBuilder.h

This was always part of the VMCore library out of necessity -- it deals
entirely in the IR. The .cpp file in fact was already part of the VMCore
library. This is just a mechanical move.

I've tried to go through and re-apply the coding standard's preferred
header sort, but at 40-ish files, I may have gotten some wrong. Please
let me know if so.

I'll be committing the corresponding updates to Clang and Polly, and
Duncan has DragonEgg.

Thanks to Bill and Eric for giving the green light for this bit of cleanup.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159421 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
3a884f5c17ac32e34e7e62b4602a0d73eeda1ce8 14-May-2012 Chad Rosier <mcrosier@apple.com> Move the capture analysis from MemoryDependencyAnalysis to a more general place
so that it can be reused in MemCpyOptimizer. This analysis is needed to remove
an unnecessary memcpy when returning a struct into a local variable.
rdar://11341081
PR12686


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@156776 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
b83a67e1e3fe210bd99a82eccd3dc5b1b44f1503 13-Feb-2012 Ahmed Charles <ace2001ac@gmail.com> Fix various issues (or do cleanups) found by enabling certain MSVC warnings.

- Use unsigned literals when the desired result is unsigned. This mostly allows unsigned/signed mismatch warnings to be less noisy even if they aren't on by default.
- Remove misplaced llvm_unreachable.
- Add static to a declaration of a function on MSVC x86 only.
- Change some instances of calling a static function through a variable to simply calling that function while removing the unused variable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150364 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a4b6fd5be08ad6a1cb2d07aba2814aaa2a626c8d 05-Dec-2011 Chad Rosier <mcrosier@apple.com> Update comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145866 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
d8bd26ee240bbc10a230d2ea8f8975d1fd32ba7c 05-Dec-2011 Chad Rosier <mcrosier@apple.com> Make the MemCpyOptimizer a bit more aggressive. I can't think of a scenerio
where this would be bad as the backend shouldn't have a problem inlining small
memcpys.
rdar://10510150

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145865 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
173862e5468fbcf4b022b9088d2c81b25c2d60c5 20-Nov-2011 Nick Lewycky <nicholas@mxc.ca> Refactor code to use new attribute getters on CallSite for NoCapture and ByVal.
Suggested in code review by Eli.

That code in InstCombine looks kinda suspicious.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145013 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
36c7e6c36cce7896b762e79a75b9a29e6a39d48c 16-Oct-2011 Nick Lewycky <nicholas@mxc.ca> When looking for dependencies on the src pointer, scan the src pointer. Scanning
on the memcpy call will pull up other unrelated stuff. Fixes PR11142.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142150 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
865703e53afb258805c9e35ea3cb346fa7eff115 12-Oct-2011 Nick Lewycky <nicholas@mxc.ca> Add missing space.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141750 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
56efe24431b045be120d1fd5f6b0aa43a6b01c48 18-Aug-2011 Eli Friedman <eli.friedman@gmail.com> Atomic load/store handling for the passes using memdep (GVN, DSE, memcpyopt).



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137888 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
db125cfaf57cc83e7dd7453de2d509bc8efd0e5e 18-Jul-2011 Chris Lattner <sabre@nondot.org> land David Blaikie's patch to de-constify Type, with a few tweaks.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135375 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
eb9a85f09e18b3fe88499710404b38d3a9128f62 14-Jul-2011 Benjamin Kramer <benny.kra@googlemail.com> Change Intrinsic::getDeclaration and friends to take an ArrayRef.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135154 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
5fdd6c8793462549e3593890ec61573da06e3346 12-Jul-2011 Jay Foad <jay.foad@gmail.com> Second attempt at de-constifying LLVM Types in FunctionType::get(),
StructType::get() and TargetData::getIntPtrType().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134982 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
2280ebd61416b73d0b6137f275b25af82e268d1f 12-Jul-2011 Bill Wendling <isanbard@gmail.com> Revert r134893 and r134888 (and related patches in other trees). It was causing
an assert on Darwin llvm-gcc builds.

Assertion failed: (castIsValid(op, S, Ty) && "Invalid cast!"), function Create, file /Users/buildslave/zorg/buildbot/smooshlab/slave-0.8/build.llvm-gcc-i386-darwin9-RA/llvm.src/lib/VMCore/Instructions.cpp, li\
ne 2067.
etc.

http://smooshlab.apple.com:8013/builders/llvm-gcc-i386-darwin9-RA/builds/2354

--- Reverse-merging r134893 into '.':
U include/llvm/Target/TargetData.h
U include/llvm/DerivedTypes.h
U tools/bugpoint/ExtractFunction.cpp
U unittests/Support/TypeBuilderTest.cpp
U lib/Target/ARM/ARMGlobalMerge.cpp
U lib/Target/TargetData.cpp
U lib/VMCore/Constants.cpp
U lib/VMCore/Type.cpp
U lib/VMCore/Core.cpp
U lib/Transforms/Utils/CodeExtractor.cpp
U lib/Transforms/Instrumentation/ProfilingUtils.cpp
U lib/Transforms/IPO/DeadArgumentElimination.cpp
U lib/CodeGen/SjLjEHPrepare.cpp
--- Reverse-merging r134888 into '.':
G include/llvm/DerivedTypes.h
U include/llvm/Support/TypeBuilder.h
U include/llvm/Intrinsics.h
U unittests/Analysis/ScalarEvolutionTest.cpp
U unittests/ExecutionEngine/JIT/JITTest.cpp
U unittests/ExecutionEngine/JIT/JITMemoryManagerTest.cpp
U unittests/VMCore/PassManagerTest.cpp
G unittests/Support/TypeBuilderTest.cpp
U lib/Target/MBlaze/MBlazeIntrinsicInfo.cpp
U lib/Target/Blackfin/BlackfinIntrinsicInfo.cpp
U lib/VMCore/IRBuilder.cpp
G lib/VMCore/Type.cpp
U lib/VMCore/Function.cpp
G lib/VMCore/Core.cpp
U lib/VMCore/Module.cpp
U lib/AsmParser/LLParser.cpp
U lib/Transforms/Utils/CloneFunction.cpp
G lib/Transforms/Utils/CodeExtractor.cpp
U lib/Transforms/Utils/InlineFunction.cpp
U lib/Transforms/Instrumentation/GCOVProfiling.cpp
U lib/Transforms/Scalar/ObjCARC.cpp
U lib/Transforms/Scalar/SimplifyLibCalls.cpp
U lib/Transforms/Scalar/MemCpyOptimizer.cpp
G lib/Transforms/IPO/DeadArgumentElimination.cpp
U lib/Transforms/IPO/ArgumentPromotion.cpp
U lib/Transforms/InstCombine/InstCombineCompares.cpp
U lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
U lib/Transforms/InstCombine/InstCombineCalls.cpp
U lib/CodeGen/DwarfEHPrepare.cpp
U lib/CodeGen/IntrinsicLowering.cpp
U lib/Bitcode/Reader/BitcodeReader.cpp



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134949 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
f362affa3a695164a94d275fb44d18f44ebb855a 11-Jul-2011 Jay Foad <jay.foad@gmail.com> De-constify Types in FunctionType::get().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134888 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
5d40ef2b1df29e726cfa093fe0acd0aa97161236 15-Jun-2011 Eli Friedman <eli.friedman@gmail.com> Stop using memdep for a check that didn't really make sense with memdep. In terms of specific issues, using memdep here checks irrelevant instructions and won't work properly once we start returning "unknown" more aggressively from memdep.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133035 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a990e071f2f29ba326b97a4288207a2c406c5b66 15-Jun-2011 Eli Friedman <eli.friedman@gmail.com> Add "unknown" results for memdep, which mean "I don't know whether a dependence for the given instruction exists in the given block". This cleans up all the existing hacks in memdep which represent this concept by returning clobber with various unrelated instructions.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133031 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
70d893e84b0de21205ad042c6c00148d0e3cd74e 02-Jun-2011 Eli Friedman <eli.friedman@gmail.com> PR10067: Add missing safety check to call return transformation in MemCpyOpt::processStore. If something accesses the dest of the "copy" between the call and the copy, the performCallSlotOptzn transformation is not valid.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132485 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
b3f0673d52b72f34434dec13c4e2044c82012ef6 23-May-2011 Chris Lattner <sabre@nondot.org> Teach valuetracking that byval arguments with a specified alignment are
aligned.

Teach memcpyopt to not give up all hope when confonted with an underaligned
memcpy feeding an overaligned byval. If the *source* of the memcpy can be
determined to be adequeately aligned, or if it can be forced to be, we can
eliminate the memcpy.

This addresses PR9794. We now compile the example into:

define i32 @f(%struct.p* nocapture byval align 8 %q) nounwind ssp {
entry:
%call = call i32 @g(%struct.p* byval align 8 %q) nounwind
ret i32 %call
}

in both x86-64 and x86-32 mode. We still don't get a tailcall though,
because tailcalls apparently can't handle byval.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131884 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
b90584ae78a7acc4ac92e3ad52121a10c520b980 04-May-2011 Devang Patel <dpatel@apple.com> Preserve line number info.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@130876 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
149f5283f93ec85b96888c284f56099a72cc2731 01-May-2011 Chris Lattner <sabre@nondot.org> enhance memcpyopt to obey -fno-builtin and friends. This addresses a
problem reported on cfe-dev.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@130661 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
7a2bdde0a0eebcd2125055e0eacaca040f0b766c 15-Apr-2011 Chris Lattner <sabre@nondot.org> Fix a ton of comment typos found by codespell. Patch by
Luis Felipe Strano Moraes!



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129558 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
ab4c366274a582dd8146b2820c6b999cad5fce36 15-Feb-2011 Duncan Sands <baldrick@free.fr> Spelling fix: consequtive -> consecutive.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125563 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
8fb25c53bdc22a1f480ac0a6c0215a23f397deb3 21-Jan-2011 Dan Gohman <gohman@apple.com> Actually check memcpy lengths, instead of just commenting about
how they should be checked.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123999 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
d318fc2ceb9d5902277f6e3b0bd7b51b92f5d872 12-Jan-2011 Chris Lattner <sabre@nondot.org> revert 123144, reenabling the rest of memset formation.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123302 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
d2e905027b3774bbc29562a5e3f64ad46bf6b0b8 12-Jan-2011 Chris Lattner <sabre@nondot.org> revert r123146 which disabled code that wasn't the root cause
of the bootstrap miscompare issue.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123299 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
2d5c0cd197454408531cd53e4dd65a431e07ba6f 12-Jan-2011 Chris Lattner <sabre@nondot.org> revert r123149, reenabling an improvement to memcpyopt that wasn't
the source of the bootstrap problem.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123298 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
f4afaa81f2d1736a4115a22c96d8188178f11cfc 10-Jan-2011 Chris Lattner <sabre@nondot.org> another random stab in the dark trying to fix llvm-gcc-i386-linux-selfhost


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123149 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a806be66c1c42ee63ef5d3878b244e91727184c3 10-Jan-2011 Chris Lattner <sabre@nondot.org> another (more) aggressive attempt to bring llvm-gcc-i386-linux-selfhost
back to life.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123146 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
d8408270f30273df2f04a8eca3e749bd0d22a2fd 10-Jan-2011 Chris Lattner <sabre@nondot.org> temporarily disable memset formation from memsets in an effort to restore buildbot stability.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123144 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
f42685004c997a4a4728cbcd9e6be1ee1d6b418f 09-Jan-2011 Chris Lattner <sabre@nondot.org> fix a few old bugs (found by inspection) where we would zap instructions
without informing memdep. This could cause nondeterminstic weirdness
based on where instructions happen to get allocated, and will hopefully
breath some life into some broken testers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123124 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
8a629577f89869f9810065dc61afd7e4302d3e46 08-Jan-2011 Chris Lattner <sabre@nondot.org> fix a latent bug in memcpyoptimizer that my recent patches exposed: it wasn't
updating memdep when fusing stores together. This fixes the crash optimizing
the bullet benchmark.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123091 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
0468e3e2654cdd0ede16efa025161ce39785eb8d 08-Jan-2011 Chris Lattner <sabre@nondot.org> tryMergingIntoMemset can only handle constant length memsets.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123090 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
d90a192279c8580c4e80d1ee102d1317ce2aaffa 08-Jan-2011 Chris Lattner <sabre@nondot.org> Merge memsets followed by neighboring memsets and other stores into
larger memsets. Among other things, this fixes rdar://8760394 and
allows us to handle "Example 2" from http://blog.regehr.org/archives/320,
compiling it into a single 4096-byte memset:

_mad_synth_mute: ## @mad_synth_mute
## BB#0: ## %entry
pushq %rax
movl $4096, %esi ## imm = 0x1000
callq ___bzero
popq %rax
ret



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123089 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
9fa11e94b5a7709cf05396420b3b3eaad6fb8e37 08-Jan-2011 Chris Lattner <sabre@nondot.org> fix an issue in IsPointerOffset that prevented us from recognizing that
P and P+1 are relative to the same base pointer.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123087 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
06511264f806cf2a55a090a555dc91a2a2e10a36 08-Jan-2011 Chris Lattner <sabre@nondot.org> enhance memcpyopt to merge a store and a subsequent
memset into a single larger memset.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123086 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
67a716ab818301fe28068754c879e568c44e62f8 08-Jan-2011 Chris Lattner <sabre@nondot.org> constify TargetData references.
Split memset formation logic out into its own
"tryMergingIntoMemset" helper function.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123081 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
61db1f56d0b717d67557bbb2a9d83af1449458cb 26-Dec-2010 Chris Lattner <sabre@nondot.org> start using irbuilder to make mem intrinsics in a few passes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122572 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
bb89710dddf967199dfc56e8bf5d28b0003f2ee6 26-Dec-2010 Chris Lattner <sabre@nondot.org> move isBytewiseValue out to ValueTracking.h/cpp


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122565 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
3fed0d917d23f4151cb8d98f122edd3229daf6ab 26-Dec-2010 Benjamin Kramer <benny.kra@googlemail.com> Simplify code.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122561 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
49c7e3e290e4633971cbeac996d8cffbe2aedc1d 24-Dec-2010 Benjamin Kramer <benny.kra@googlemail.com> Fix a thinko pointed out by Frits van Bommel: looking through global variables in isBytewiseValue is not safe.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122550 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a112087e4298ca8ec1bc8aef8a2b272e49faa7ac 24-Dec-2010 Benjamin Kramer <benny.kra@googlemail.com> MemCpyOpt: Turn memcpys from a constant into a memset if possible.

This allows us to compile "int cst[] = {-1, -1, -1};" into
movl $-1, 16(%rsp)
movq $-1, 8(%rsp)
instead of
movl _cst+8(%rip), %eax
movl %eax, 16(%rsp)
movq _cst(%rip), %rax
movq %rax, 8(%rsp)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122548 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
8e68c3873549ca31533e2e3e40dda3a43cb79566 23-Dec-2010 Jeffrey Yasskin <jyasskin@google.com> Change all self assignments X=X to (void)X, so that we can turn on a
new gcc warning that complains on self-assignments and
self-initializations.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122458 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
387f28aff41bae6a81311279b203a1281eaa443a 16-Dec-2010 Dan Gohman <gohman@apple.com> Make memcpyopt TBAA-aware.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121944 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
8fdca6a8738c1ad7091137688ee48c9e623b75bb 09-Dec-2010 Chris Lattner <sabre@nondot.org> enhance memcpyopt to zap memcpy's that have the same src/dst.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121362 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
f7f35467a9aac818bd5813c17e80d7efb66dadd7 09-Dec-2010 Chris Lattner <sabre@nondot.org> fix PR8753, eliminating a case where we'd infinitely make a
substitution because it doesn't actually change the IR. Patch by
Jakub Staszak!



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121361 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
40f8f6264d5af2c38e797e0dc59827cd231e8ff7 07-Dec-2010 Jay Foad <jay.foad@gmail.com> PR5207: Change APInt methods trunc(), sext(), zext(), sextOrTrunc() and
zextOrTrunc(), and APSInt methods extend(), extOrTrunc() and new method
trunc(), to be const and to return a new value instead of modifying the
object in place.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121120 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
b5a3196f809e8edb2e9fef09de1de3d382cb852f 01-Dec-2010 Chris Lattner <sabre@nondot.org> fix a bozo bug I introduced in r119930, causing a miscompile of
20040709-1.c from the gcc testsuite. I was using the size of a
pointer instead of the pointee. This fixes rdar://8713376


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120519 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
7a0b4fdd143a8333453dbfa1a85af641c98b5ca4 30-Nov-2010 Chris Lattner <sabre@nondot.org> prune an llvmcontext include and simplify some code.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120347 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
6ffdd45d865bce08a90b877e5e0281e146da5b3a 21-Nov-2010 Chris Lattner <sabre@nondot.org> fix comment


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119948 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
604f6fe553eb430c6d991f72baa3633842759b49 21-Nov-2010 Chris Lattner <sabre@nondot.org> rework some DSE paths to use the newly-public "getPointerDependencyFrom"
method in MemDep instead of inserting an instruction, doing a query,
then removing it. Neither operation is effectively cached.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119930 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
2f5f90ad3e9b00cf21ae8e3f55b93f0be1d504c3 21-Nov-2010 Chris Lattner <sabre@nondot.org> Implement PR8644: forwarding a memcpy value to a byval,
allowing the memcpy to be eliminated.

Unfortunately, the requirements on byval's without explicit
alignment are really weak and impossible to predict in the
mid-level optimizer, so this doesn't kick in much with current
frontends. The fix is to change clang to set alignment on all
byval arguments.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119916 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
f601d6df6f43bb833461cbcee475c36998e6c259 20-Nov-2010 Benjamin Kramer <benny.kra@googlemail.com> Simplify code. No change in functionality.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119908 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
d528be6636539567194981a8c0f8b90220bec0a5 18-Nov-2010 Chris Lattner <sabre@nondot.org> slightly simplify code and substantially improve comment. Instead of
saying "it would be bad", give an example of what is going on.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119695 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
5a7aeaa01904b9b0adf256108f302f8961295754 18-Nov-2010 Chris Lattner <sabre@nondot.org> remove a pointless restriction from memcpyopt. It was
refusing to optimize two memcpy's like this:

copy A <- B
copy C <- A

if it couldn't prove that noalias(B,C). We can eliminate
the copy by producing a memmove instead of memcpy.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119694 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
12f7085027657957e08aea597b5c9fed44052969 18-Nov-2010 Chris Lattner <sabre@nondot.org> remove another pointless noalias check: M is a memcpy, so the
source and dest are known to not overlap.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119692 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
245b7f6ec26a8d27c984da4cceb7cfc27abcba6b 18-Nov-2010 Chris Lattner <sabre@nondot.org> use AA::isNoAlias instead of open coding it. Remove an extraneous noalias check:
there is no need to check to see if the source and dest of a memcpy are noalias,
behavior is undefined if not.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119691 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
43f8e43eb2a166f50c3a077040d8bdb24104433a 18-Nov-2010 Chris Lattner <sabre@nondot.org> rearrange some code, splitting memcpy/memcpy optimization
out of processMemCpy into its own function.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119687 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
3da848bbda62b25c12335998aaa44ab361f0bf15 20-Oct-2010 Dan Gohman <gohman@apple.com> Reapply r116831 and r116839, converting AliasAnalysis to use
uint64_t, plus fixes for places I missed before.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116875 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
1db839e73471a40309c2c10873b67c3b5b1b7a7b 19-Oct-2010 Dan Gohman <gohman@apple.com> Revert r116831 and r116839, which are breaking selfhost builds.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116858 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
9cb4c7f87876ec8212bd4fae059553fcaa83f484 19-Oct-2010 Dan Gohman <gohman@apple.com> Oops, check in all the files for converting AliasAnalysis to
use uint64_t.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116839 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
081c34b725980f995be9080eaec24cd3dfaaf065 19-Oct-2010 Owen Anderson <resistor@mac.com> Get rid of static constructors for pass registration. Instead, every pass exposes an initializeMyPassFunction(), which
must be called in the pass's constructor. This function uses static dependency declarations to recursively initialize
the pass's dependencies.

Clients that only create passes through the createFooPass() APIs will require no changes. Clients that want to use the
CommandLine options for passes will need to manually call the appropriate initialization functions in PassInitialization.h
before parsing commandline arguments.

I have tested this with all standard configurations of clang and llvm-gcc on Darwin. It is possible that there are problems
with the static dependencies that will only be visible with non-standard options. If you encounter any crash in pass
registration/creation, please send the testcase to me directly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116820 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
f3a925dc7a14ade42da442b49c304c064954c1d4 19-Oct-2010 Dan Gohman <gohman@apple.com> Consistently use AliasAnalysis::UnknownSize instead of hardcoding ~0u.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116815 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
6549121c660dfd18361cd3daf6c766bee80d3097 16-Oct-2010 Owen Anderson <resistor@mac.com> Generalize MemCpyOpt's handling of call slot forwarding to function properly when the call slot
forwarding is implemented with a load/store pair rather than a memcpy.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116637 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
2ab36d350293c77fc8941ce1023e4899df7e3a82 12-Oct-2010 Owen Anderson <resistor@mac.com> Begin adding static dependence information to passes, which will allow us to
perform initialization without static constructors AND without explicit initialization
by the client. For the moment, passes are required to initialize both their
(potential) dependencies and any passes they preserve. I hope to be able to relax
the latter requirement in the future.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116334 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
ce665bd2e2b581ab0858d1afe359192bac96b868 08-Oct-2010 Owen Anderson <resistor@mac.com> Now with fewer extraneous semicolons!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115996 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
04fcbf954fef6d9866b5120f406e7401dc9aa29f 01-Oct-2010 Eric Christopher <echristo@apple.com> Fix the other half of the alignment changing issue by making sure that the
memcpy alignment is the minimum of the incoming alignments.

Fixes PR 8266.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115305 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
c69a00047013a0e2e07ae44c38e013a7d905b10e 25-Sep-2010 Eric Christopher <echristo@apple.com> If we're changing the source of a memcpy we need to use the alignment
of the source, not the original alignment since it may no longer
be valid.

Fixes rdar://8400094


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114781 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
90c579de5a383cee278acc3f7e7b9d0a656e6a35 06-Aug-2010 Owen Anderson <resistor@mac.com> Reapply r110396, with fixes to appease the Linux buildbot gods.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110460 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
1f74590e9d1b9cf0f1f81a156efea73f76546e05 06-Aug-2010 Owen Anderson <resistor@mac.com> Revert r110396 to fix buildbots.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110410 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
9ccaf53ada99c63737547c0235baeb8454b04e80 06-Aug-2010 Owen Anderson <resistor@mac.com> Don't use PassInfo* as a type identifier for passes. Instead, use the address of the static
ID member as the sole unique type identifier. Clean up APIs related to this change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110396 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
7d3056b16038a6a09c452c0dfcc3c8f4e421506a 29-Jul-2010 Gabor Greif <ggreif@gmail.com> simplify by using CallSite constructors; virtually eliminates CallSite::get from the tree

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109687 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a292b2f49f1557f234e9fa987da690c6d24118e5 27-Jul-2010 Gabor Greif <ggreif@gmail.com> recommit simplification (r109502, backed out r109509); seems to innocent

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109510 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
5b0c25313e4bbb6190b58e105eec38957c388a64 27-Jul-2010 Gabor Greif <ggreif@gmail.com> back out this too to restore the bots

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109509 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
50da18171e17d22ef8009f01b7b4f332c5ec24ab 27-Jul-2010 Gabor Greif <ggreif@gmail.com> simplify

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109502 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a399781289092fcdceb58b21174229f4373c4191 22-Jul-2010 Gabor Greif <ggreif@gmail.com> undo 80 column trespassing I caused

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109092 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
d13db2c59cc94162d6cf0a04187d408bfef6d4a7 22-Jul-2010 Owen Anderson <resistor@mac.com> Fix batch of converting RegisterPass<> to INTIALIZE_PASS().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109045 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
fe60104ac97f3a8736dcfbfdf9547c7b7cc7b951 22-Jun-2010 Dan Gohman <gohman@apple.com> Use pre-increment instead of post-increment when the result is not used.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@106542 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a9b2313c13a1bc8cbae751da03a9049ecaf0f918 20-Apr-2010 Gabor Greif <ggreif@gmail.com> use abstract accessors to CallInst

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101899 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
551754c4958086cc6910da7c950f2875e212f5cf 17-Apr-2010 Eric Christopher <echristo@apple.com> Revert 101465, it broke internal OpenGL testing.

Probably the best way to know that all getOperand() calls have been handled
is to replace that API instead of updating.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101579 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
4ec2258ffb495d7ce00177e447740ef1123a27db 16-Apr-2010 Gabor Greif <ggreif@gmail.com> reapply r101434
with a fix for self-hosting

rotate CallInst operands, i.e. move callee to the back
of the operand array

the motivation for this patch are laid out in my mail to llvm-commits:
more efficient access to operands and callee, faster callgraph-construction,
smaller compiler binary


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101465 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
607a7ab3da72a2eb53553a520507cbb8068dd1d8 16-Apr-2010 Gabor Greif <ggreif@gmail.com> back out r101423 and r101397, they break llvm-gcc self-host on darwin10

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101434 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
2ff961f66816daab8bbc58a19025161d969821c2 15-Apr-2010 Gabor Greif <ggreif@gmail.com> reapply r101364, which has been backed out in r101368
with a fix

rotate CallInst operands, i.e. move callee to the back
of the operand array

the motivation for this patch are laid out in my mail to llvm-commits:
more efficient access to operands and callee, faster callgraph-construction,
smaller compiler binary


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101397 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
9ee17208115482441953127615231c59a2f4d052 15-Apr-2010 Gabor Greif <ggreif@gmail.com> back out r101364, as it trips the linux nightlybot on some clang C++ tests

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101368 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
165dac08d1bb8428b32a5f39cdd3dbee2888987f 15-Apr-2010 Gabor Greif <ggreif@gmail.com> rotate CallInst operands, i.e. move callee to the back
of the operand array

the motivation for this patch are laid out in my mail to llvm-commits:
more efficient access to operands and callee, faster callgraph-construction,
smaller compiler binary


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101364 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
20adc9dc4650313f017b27d9818eb2176238113d 04-Apr-2010 Mon P Wang <wangmp@apple.com> Reapply address space patch after fixing an issue in MemCopyOptimizer.
Added support for address spaces and added a isVolatile field to memcpy, memmove, and memset,
e.g., llvm.memcpy.i32(i8*, i8*, i32, i32) -> llvm.memcpy.p0i8.p0i8.i32(i8*, i8*, i32, i32, i1)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100304 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
e754d3fb852abdeaf910c7331eed60f6303597c1 02-Apr-2010 Mon P Wang <wangmp@apple.com> Revert r100191 since it breaks objc in clang


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100199 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
e33c848fa481b038d5ad0c7c898c33b2b27ec71e 02-Apr-2010 Mon P Wang <wangmp@apple.com> Reapply address space patch after fixing an issue in MemCopyOptimizer.
Added support for address spaces and added a isVolatile field to memcpy, memmove, and memset,
e.g., llvm.memcpy.i32(i8*, i8*, i32, i32) -> llvm.memcpy.p0i8.p0i8.i32(i8*, i8*, i32, i32, i1)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100191 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
100f090adde26005b9f1eca96871dff52825b27b 31-Mar-2010 Bob Wilson <bob.wilson@apple.com> Revert Mon Ping's change 99928, since it broke all the llvm-gcc buildbots.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99948 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
808bab0169ab7d2e8dfdc72dd2c991cd8ff2396d 30-Mar-2010 Mon P Wang <wangmp@apple.com> Added support for address spaces and added a isVolatile field to memcpy, memmove, and memset,
e.g., llvm.memcpy.i32(i8*, i8*, i32, i32) -> llvm.memcpy.p0i8.p0i8.i32(i8*, i8*, i32, i32, i1)
A update of langref will occur in a subsequent checkin.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99928 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
b0bc6c361da9009e8414efde317d9bbff755f6c0 15-Feb-2010 Duncan Sands <baldrick@free.fr> Uniformize the names of type predicates: rather than having isFloatTy and
isInteger, we now have isFloatTy and isIntegerTy. Requested by Chris!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96223 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
11acaa374cdcebb161bf0de5f244265d78a749c1 05-Jan-2010 Benjamin Kramer <benny.kra@googlemail.com> Convert a ton of simple integer type equality tests to the new predicate.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92760 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
321a813c536e2f1f2f05bbe78a7fbf64046f0557 05-Jan-2010 Dan Gohman <gohman@apple.com> Use do+while instead of while for loops which obviously have a
non-zero trip count. Use SmallVector's pop_back_val().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92734 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
cb33fd17cce475a1d47b2695e311b6934ad0ef86 05-Jan-2010 David Greene <greened@obbligato.org> Change errs() to dbgs().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92624 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
ac53a0b272452013124bfc70480aea5e41b60f40 06-Oct-2009 Duncan Sands <baldrick@free.fr> Introduce and use convenience methods for getting pointer types
where the element is of a basic builtin type. For example, to get
an i8* use getInt8PtrTy.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83379 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
cf0fe8d813727383d630055bb9d1cde21b00b7e7 05-Oct-2009 Chris Lattner <sabre@nondot.org> strength reduce a ton of type equality tests to check the typeid (Through
the new predicates I added) instead of going through a context and doing a
pointer comparison. Besides being cheaper, this allows a smart compiler
to turn the if sequence into a switch.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83297 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
264d245851173bbace9281a2378a6cc51162b030 15-Sep-2009 Dan Gohman <gohman@apple.com> When extending a memset range past the front, set the alignment of the
memset region to the alignment of the new start address.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81810 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
ff1e98c72ae5f2aa805112925fd5c06049aa8e79 08-Sep-2009 Chris Lattner <sabre@nondot.org> Fix PR4882, by making MemCpyOpt not dereference removed stores to get the
context for the newly created operations.

Patch by Jakub Staszak!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81175 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
05cd03b33559732f8ed55e5ff7554fd06d59eb6a 03-Sep-2009 Duncan Sands <baldrick@free.fr> Keep track of how many memmove calls were turned into
memcpy calls.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80915 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
3e8b6631e67e01e4960a7ba4668a50c596607473 02-Sep-2009 Chris Lattner <sabre@nondot.org> eliminate VISIBILITY_HIDDEN from Transforms/Scalar. PR4861


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80766 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
f41eaacee4a4a2d4339dd553626d98c73650c8c7 01-Sep-2009 Chris Lattner <sabre@nondot.org> enhance memcpy opt to turn memmoves into memcpy when the src/dest
don't alias. Remove an old and poorly reduced testcase that fails
with this transform for reasons unrelated to the original test.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80693 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
61c6ba85715fdcb66f746678879984151f1e5485 01-Sep-2009 Chris Lattner <sabre@nondot.org> random code cleanups, no functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80682 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
bdff548e4dd577a72094d57b282de4e765643b96 23-Aug-2009 Chris Lattner <sabre@nondot.org> eliminate the "Value" printing methods that print to a std::ostream.
This required converting a bunch of stuff off DOUT and other cleanups.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79819 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
8942f9bb9f8bfb0d113db6d4a1ae7203dcf4510a 18-Aug-2009 Dan Gohman <gohman@apple.com> Make TargetData optional in MemCpyOptimizer.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79306 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
1d0be15f89cb5056e20e2d24faa8d6afb1573bca 13-Aug-2009 Owen Anderson <resistor@mac.com> Push LLVMContexts through the IntegerType APIs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78948 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
debcb01b0f0a15f568ca69e8f288fade4bfc7297 30-Jul-2009 Owen Anderson <resistor@mac.com> Move types back to the 2.5 API.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77516 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
baf3c404409d5e47b13984a7f95bfbd6d1f2e79e 29-Jul-2009 Owen Anderson <resistor@mac.com> Move ConstantExpr to 2.5 API.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77494 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a195b7ffd6612a331751c7b6042d5cd921ee586c 28-Jul-2009 Dan Gohman <gohman@apple.com> Grab the LLVMContext and parent Module of SI ahead of the
point where SI can get deleted. This fixes a use of free'd memory.
This fixes Externals/Povray.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77285 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
460f656475738d1a95a6be95346908ce1597df25 26-Jul-2009 Daniel Dunbar <daniel@zuster.org> Remove Value::getName{Start,End}, the last of the old Name APIs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77152 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
eed707b1e6097aac2bb6b3d47271f6300ace7f2e 25-Jul-2009 Owen Anderson <resistor@mac.com> Revert the ConstantInt constructors back to their 2.5 forms where possible, thanks to contexts-on-types. More to come.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77011 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
e922c0201916e0b980ab3cfe91e1413e68d55647 22-Jul-2009 Owen Anderson <resistor@mac.com> Get rid of the Pass+Context magic.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76702 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
fa5cbd6d0fbda23fd669c8718e07b19001b2d21a 03-Jul-2009 Owen Anderson <resistor@mac.com> Even more passes being LLVMContext'd.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74781 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
777d2306b36816a53bc1ae1244c0dc7d998ae691 09-May-2009 Duncan Sands <baldrick@free.fr> Rename PaddedSize to AllocSize, in the hope that this
will make it more obvious what it represents, and stop
it being confused with the StoreSize.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@71349 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
9c0f146d50ccc3ba780d4854b8e14422430013ef 19-Mar-2009 Nick Lewycky <nicholas@mxc.ca> Remove strange extra semicolons.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67287 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
dfe964ce8c367248e587f2d9ecc7fac5ee2c6fdc 08-Mar-2009 Chris Lattner <sabre@nondot.org> change the MemIntrinsic get/setAlignment method to take an unsigned
instead of a Constant*, which is what the clients of it really want.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66364 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
ceb4d1aecb9deffe59b3dcdc9a783ffde8477be9 12-Jan-2009 Duncan Sands <baldrick@free.fr> Rename getABITypeSize to getTypePaddedSize, as
suggested by Chris.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62099 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
b51deb929ca95ce62e622b0475a05d83f26ab04d 05-Dec-2008 Chris Lattner <sabre@nondot.org> Make a few major changes to memdep and its clients:
1. Merge the 'None' result into 'Normal', making loads
and stores return their dependencies on allocations as Normal.
2. Split the 'Normal' result into 'Clobber' and 'Def' to
distinguish between the cases when memdep knows the value is
produced from when we just know if may be changed.
3. Move some of the logic for determining whether readonly calls
are CSEs into memdep instead of it being in GVN. This still
leaves verification that the arguments are hte same to GVN to
let it know about value equivalences in different contexts.
4. Change memdep's call/call dependency analysis to use
getModRefInfo(CallSite,CallSite) instead of doing something
very weak. This only really matters for things like DSA, but
someday maybe we'll have some other decent context sensitive
analyses :)
5. This reimplements the guts of memdep to handle the new results.
6. This simplifies GVN significantly:
a) readonly call CSE is slightly simpler
b) I eliminated the "getDependencyFrom" chaining for load
elimination and load CSE doesn't have to worry about
volatile (they are always clobbers) anymore.
c) GVN no longer does any 'lastLoad' caching, leaving it to
memdep.
7. The logic in DSE is simplified a bit and sped up. A potentially
unsafe case was eliminated.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60607 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
4f8c18c7c757875cfa45383e7cf33d65d2c4d564 30-Nov-2008 Chris Lattner <sabre@nondot.org> Eliminate the dropInstruction method, which is not needed any more.
Fix a subtle iterator invalidation bug I introduced in the last commit.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60258 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
4c724006256032e827177afeae04ea62436796e7 29-Nov-2008 Chris Lattner <sabre@nondot.org> Introduce and use a new MemDepResult class to hold the results of a memdep
query. This makes it crystal clear what cases can escape from MemDep that
the clients have to handle. This also gives the clients a nice simplified
interface to it that is easy to poke at.

This patch also makes DepResultTy and MemoryDependenceAnalysis::DepType
private, yay.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60231 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
39f372e23e49cecb8db2eb7120eb331173e50c74 29-Nov-2008 Chris Lattner <sabre@nondot.org> Reimplement the internal abstraction used by MemDep in terms
of a pointer/int pair instead of a manually bitmangled pointer.
This forces clients to think a little more about checking the
appropriate pieces and will be useful for internal
implementation improvements later.

I'm not particularly happy with this. After going through this
I don't think that the clients of memdep should be exposed to
the internal type at all. I'll fix this in a subsequent commit.

This has no functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60230 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
824b958e6fb1236e92e4d07f3acf18fca107cdc0 21-Nov-2008 Chris Lattner <sabre@nondot.org> reapply Sanjiv's patch to genericize memcpy/memset/memmove to take an
arbitrary integer width for the count.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59823 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
dc770929cb2f97397970e2942b746839fc387992 21-Nov-2008 Bill Wendling <isanbard@gmail.com> Revert r59802. It was breaking the build of llvm-gcc:

g++ -m32 -c -g -DIN_GCC -W -Wall -Wwrite-strings -Wmissing-format-attribute -fno-common -mdynamic-no-pic -DHAVE_CONFIG_H -Wno-unused -DTARGET_NAME=\"i386-apple-darwin9.5.0\" -I. -I. -I../../llvm-gcc.src/gcc -I../../llvm-gcc.src/gcc/. -I../../llvm-gcc.src/gcc/../include -I./../intl -I../../llvm-gcc.src/gcc/../libcpp/include -I../../llvm-gcc.src/gcc/../libdecnumber -I../libdecnumber -I/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvm.obj/include -I/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvm.src/include -DENABLE_LLVM -I/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvm.obj/../llvm.src/include -D_DEBUG -D_GNU_SOURCE -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -I. -I. -I../../llvm-gcc.src/gcc -I../../llvm-gcc.src/gcc/. -I../../llvm-gcc.src/gcc/../include -I./../intl -I../../llvm-gcc.src/gcc/../libcpp/include -I../../llvm-gcc.src/gcc/../libdecnumber -I../libdecnumber -I/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvm.obj/include -I/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvm.src/include ../../llvm-gcc.src/gcc/llvm-types.cpp -o llvm-types.o
../../llvm-gcc.src/gcc/llvm-convert.cpp: In member function 'void TreeToLLVM::EmitMemCpy(llvm::Value*, llvm::Value*, llvm::Value*, unsigned int)':
../../llvm-gcc.src/gcc/llvm-convert.cpp:1496: error: 'memcpy_i32' is not a member of 'llvm::Intrinsic'
../../llvm-gcc.src/gcc/llvm-convert.cpp:1496: error: 'memcpy_i64' is not a member of 'llvm::Intrinsic'
../../llvm-gcc.src/gcc/llvm-convert.cpp: In member function 'void TreeToLLVM::EmitMemMove(llvm::Value*, llvm::Value*, llvm::Value*, unsigned int)':
../../llvm-gcc.src/gcc/llvm-convert.cpp:1512: error: 'memmove_i32' is not a member of 'llvm::Intrinsic'
../../llvm-gcc.src/gcc/llvm-convert.cpp:1512: error: 'memmove_i64' is not a member of 'llvm::Intrinsic'
../../llvm-gcc.src/gcc/llvm-convert.cpp: In member function 'void TreeToLLVM::EmitMemSet(llvm::Value*, llvm::Value*, llvm::Value*, unsigned int)':
../../llvm-gcc.src/gcc/llvm-convert.cpp:1528: error: 'memset_i32' is not a member of 'llvm::Intrinsic'
../../llvm-gcc.src/gcc/llvm-convert.cpp:1528: error: 'memset_i64' is not a member of 'llvm::Intrinsic'
make[3]: *** [llvm-convert.o] Error 1
make[3]: *** Waiting for unfinished jobs....
rm fsf-funding.pod gcov.pod gfdl.pod cpp.pod gpl.pod gcc.pod
make[2]: *** [all-stage1-gcc] Error 2
make[1]: *** [stage1-bubble] Error 2
make: *** [all] Error 2



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59809 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
219ab405e6bea993da14cf3ce7b50983c3bb7a6f 21-Nov-2008 Sanjiv Gupta <sanjiv.gupta@microchip.com> Make mem[cpy,move,set] intrinsics overloaded.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59802 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
eaf42abab6d465c38891345d999255871cf03943 24-Sep-2008 Devang Patel <dpatel@apple.com> s/ParameterAttributes/Attributes/g



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56513 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
ae73dc1448d25b02cabc7c64c86c64371453dda8 04-Sep-2008 Dan Gohman <gohman@apple.com> Tidy up several unbeseeming casts from pointer to intptr_t.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@55779 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
009e4f760969e3530cc2641a9599e646a20580c2 02-Jun-2008 Owen Anderson <resistor@mac.com> Fix two issues that Eli Friedman pointed out, where would misoptimized code like:

char a[200];
init(a, a+200);

OR

int a[200];
char* b = (char*)a;
char* c = (char*)a;
foo(b, c);


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51850 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
12cb36c11564e2a7cf85b4b29bddab5c5fd63cf5 01-Jun-2008 Owen Anderson <resistor@mac.com> Don't remove the memcpy when call slot substitution fails.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51848 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
7cbd8a3e92221437048b484d5ef9c0a22d0f8c58 16-May-2008 Gabor Greif <ggreif@gmail.com> API change for {BinaryOperator|CmpInst|CastInst}::create*() --> Create. Legacy interfaces will be in place for some time. (Merge from use-diet branch.)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51200 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
529bd53411c6f583fd8ed435adf4c0f923d185fd 04-May-2008 Torok Edwin <edwintorok@gmail.com> processStore may delete the instruction, avoid
using dyn_cast<> on already freed memory.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50618 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
02e9988020acb3e8b0271aa9ebc7c8e770c8a85f 29-Apr-2008 Owen Anderson <resistor@mac.com> Revert r50441. The original code was correct. Add some more comments so that I don't make the same mistake in the future.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50446 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
9dcace3cafb4da5c3d94f3b89e54ea0d7164a286 29-Apr-2008 Owen Anderson <resistor@mac.com> Fix a bug in memcpyopt where the memcpy-memcpy transform was never being applied because
we were checking for it in the wrong order. This caused a miscompilation because the
return slot optimization assumes that the call it is dealing with is NOT a memcpy.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50444 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
7b6fafaa8d2cd98c37a8978e8ccbbba91f834b3d 29-Apr-2008 Owen Anderson <resistor@mac.com> We should be returning true here since we've changed the function.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50442 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a8bd65835be9e1ce07f5006e92625ec4e9fa387a 21-Apr-2008 Owen Anderson <resistor@mac.com> Refactor memcpyopt based on Chris' suggestions. Consolidate several functions
and simplify code that was fallout from the separation of memcpyopt and gvn.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50034 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
a723d1e48f4a261512c28845c53eda569fa5218c 09-Apr-2008 Owen Anderson <resistor@mac.com> Factor a bunch of functionality related to memcpy and memset transforms out of
GVN and into its own pass.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49419 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp