mirror of
https://github.com/kmc7468/cs420.git
synced 2025-12-15 06:58:50 +00:00
Update skeleton
This commit is contained in:
@@ -30,6 +30,7 @@ if
|
||||
grep 'too many arguments in call' out.txt ||\
|
||||
grep 'declaration does not declare anything' out.txt ||\
|
||||
grep 'not equal to a null pointer is always true' out.txt ||\
|
||||
grep 'empty struct is a GNU extension' out.txt ||\
|
||||
! gcc -Wall -Wextra -O2 test_reduced.c > outa.txt 2>&1 ||\
|
||||
grep 'uninitialized' outa.txt ||\
|
||||
grep 'without a cast' outa.txt ||\
|
||||
@@ -49,10 +50,16 @@ if
|
||||
grep 'excess elements in struct initializer' outa.txt ||\
|
||||
grep 'comparison between pointer and integer' outa.txt ||\
|
||||
! gcc -O1 test_reduced.c > cc_out1.txt 2>&1 ||\
|
||||
! gcc -O2 test_reduced.c > cc_out2.txt 2>&1)
|
||||
! gcc -O2 test_reduced.c > cc_out2.txt 2>&1 ||\
|
||||
! cargo run --manifest-path $PROJECT_DIR/Cargo.toml --release -- --parse test_reduced.c >/dev/null 2>&1)
|
||||
then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cargo run --manifest-path $PROJECT_DIR/Cargo.toml --release -- --parse test_reduced.c >/dev/null 2>&1 &&\
|
||||
! cargo run --manifest-path $PROJECT_DIR/Cargo.toml --release --bin fuzz -- $FUZZ_ARG test_reduced.c
|
||||
cargo run --manifest-path $PROJECT_DIR/Cargo.toml --release --bin fuzz -- $FUZZ_ARG test_reduced.c
|
||||
if [ "$?" = 101 ]
|
||||
then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -83,3 +83,12 @@ fn test_examples_mem2reg() {
|
||||
&mut Mem2reg::default(),
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_examples_gvn() {
|
||||
test_opt(
|
||||
&Path::new("examples/gvn/gvn.input.ir"),
|
||||
&Path::new("examples/gvn/gvn.output.ir"),
|
||||
&mut Gvn::default(),
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user