LLVM backend for 6502
Go to file
Meador Inge 0c4cbc33dd Remove hard-coded constant in Transforms/InstCombine/memcmp-1.ll
Transforms/InstCombine/memcmp-1.ll has a test case that looks like:

  @foo = constant [4 x i8] c"foo\00"
  @hel = constant [4 x i8] c"hel\00"

  ...

  %mem1 = getelementptr [4 x i8]* @hel, i32 0, i32 0
  %mem2 = getelementptr [4 x i8]* @foo, i32 0, i32 0
  %ret = call i32 @memcmp(i8* %mem1, i8* %mem2, i32 3)
  ret i32 %ret
  ; CHECK: ret i32 2

The folded return value (2 above) is computed using the system memcmp
that the compiler is linked with.  This can return different values on
different systems.  The test was originally written on an OS X 10.7.5
x86-64 box and passed.  However, it failed on one of the x86-64 FreeBSD
buildbots because the system memcpy on that machine returned a different
value (1 instead of 2).

I fixed the test by checking the folding constants with regexes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167691 91177308-0d34-0410-b5e6-96231b3b80d8
2012-11-11 07:10:25 +00:00
autoconf Add mips64-* and mips64el-* triples to configure scripts 2012-10-29 19:49:45 +00:00
bindings Fix a build error for ocaml bindings that was introduced with the TargetData --> DataLayout changes. 2012-10-19 20:36:22 +00:00
cmake CMake: Include private headers / tablegen files in generated Xcode projects. 2012-10-23 21:36:55 +00:00
docs Update the vectorizer docs. 2012-11-11 06:47:51 +00:00
examples Back out r166591, not sure why this made it through since I cancelled the command. Bleh, sorry about this! 2012-10-24 17:25:11 +00:00
include Add method for replacing instructions to LibCallSimplifier 2012-11-11 03:51:43 +00:00
lib instcombine: Migrate memset optimizations 2012-11-11 06:49:03 +00:00
projects Add mips64-* and mips64el-* triples to configure scripts 2012-10-29 19:49:45 +00:00
runtime libprofile/CommonProfiling.c: Fix according to C89. 2012-11-02 01:32:02 +00:00
test Remove hard-coded constant in Transforms/InstCombine/memcmp-1.ll 2012-11-11 07:10:25 +00:00
tools Add a relocation visitor to lib object. This works via caching relocated 2012-11-07 23:22:07 +00:00
unittests Provide definitions for all functions. 2012-11-10 16:10:16 +00:00
utils Simplify the SmallVector pretty printer for LLDB a bit and make it work with reference types. 2012-11-10 09:45:32 +00:00
.gitignore
CMakeLists.txt
CODE_OWNERS.TXT
configure Add mips64-* and mips64el-* triples to configure scripts 2012-10-29 19:49:45 +00:00
CREDITS.TXT
LICENSE.TXT
llvm.spec.in
LLVMBuild.txt
Makefile [c-index-test] When building with BUILD_CLANG_ONLY=YES, include c-index-test. 2012-11-06 19:54:46 +00:00
Makefile.common
Makefile.config.in
Makefile.rules Use MACOSX_DEPLOYMENT_TARGET when it is set. <rdar://problem/12433905> 2012-10-12 21:48:14 +00:00
README.txt

Low Level Virtual Machine (LLVM)
================================

This directory and its subdirectories contain source code for the Low Level
Virtual Machine, a toolkit for the construction of highly optimized compilers,
optimizers, and runtime environments.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.

Please see the HTML documentation provided in docs/index.html for further
assistance with LLVM.

If you're writing a package for LLVM, see docs/Packaging.html for our
suggestions.