diff options
author | Reid Spencer <rspencer@reidspencer.com> | 2005-04-25 07:29:30 +0000 |
---|---|---|
committer | Reid Spencer <rspencer@reidspencer.com> | 2005-04-25 07:29:30 +0000 |
commit | 0bc07503c8a124f5bafb04be64e4fd458c2a8a74 (patch) | |
tree | a5215b4c6fc85b3952b8903b4d800a080cf5fc4e | |
parent | b7c11e3966abbad0cf005ca87bcee46aafe48bed (diff) |
A test case for testing the StrCatOptimizer, currently XFAILed everywhere.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21532 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | test/Transforms/SimplifyLibCalls/2005-04-24-strcat.ll | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/Transforms/SimplifyLibCalls/2005-04-24-strcat.ll b/test/Transforms/SimplifyLibCalls/2005-04-24-strcat.ll new file mode 100644 index 0000000000..d6040603f0 --- /dev/null +++ b/test/Transforms/SimplifyLibCalls/2005-04-24-strcat.ll @@ -0,0 +1,16 @@ +; Test that the StrCatOptimizer works correctly +; RUN: llvm-as < %s | opt -simplify-libcalls | llvm-dis | grep strlen +; XFAIL: * + +declare sbyte* %strcat(sbyte*,sbyte*) +%hello = constant [6 x sbyte] c"hello\00" + +implementation ; Functions: + +int %main () { + %target = alloca [1024 x sbyte] + %arg1 = getelementptr [1024 x sbyte]* %target, int 0, int 0 + %arg2 = getelementptr [6 x sbyte]* %hello, int 0, int 0 + %rslt = call sbyte* %strcat(sbyte* %arg1, sbyte* %arg2) + ret int 0 +} |