mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-13 15:11:39 +00:00
Two testcases for loops: one with outputs, one without.
llvm-svn: 11934
This commit is contained in:
parent
84f00e93f7
commit
26992f4a8c
13
test/Regression/Transforms/CodeExtractor/loops-no-output.c
Normal file
13
test/Regression/Transforms/CodeExtractor/loops-no-output.c
Normal file
@ -0,0 +1,13 @@
|
||||
#include <stdio.h>
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
int i;
|
||||
for (i=0; i < 5; ++i)
|
||||
printf("%d\n", i);
|
||||
|
||||
printf("separator!\n");
|
||||
|
||||
for (i=0; i < 4; ++i)
|
||||
printf("[%d]\n", i+5);
|
||||
return 0;
|
||||
}
|
13
test/Regression/Transforms/CodeExtractor/loops-outputs.c
Normal file
13
test/Regression/Transforms/CodeExtractor/loops-outputs.c
Normal file
@ -0,0 +1,13 @@
|
||||
#include <stdio.h>
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
int i, d=0;
|
||||
for (i=0; i < 10; ++i)
|
||||
d += i;
|
||||
|
||||
printf("separator!\n");
|
||||
|
||||
for (i=0; i < 4; ++i)
|
||||
printf("[%d]\n", d+i);
|
||||
return 0;
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user