1 # Analog Devices Blackfin simulator testsuite
3 if [istarget bfin-*-elf] {
4 # Used to locate the `run` program.
11 # See if we have a preprocessor available.
12 if { [target_compile $srcdir/$subdir/usp.S compilercheck.x "preprocess" \
13 [list "incdir=$srcdir/$subdir"]] == "" } {
16 verbose -log "Can't execute preprocessor"
20 # See if we have a compiler available.
21 if { [target_compile $srcdir/$subdir/argc.c compilercheck.x "executable" \
22 [list "incdir=$srcdir/$subdir" "additional_flags=-msim"]] == "" } {
25 verbose -log "Can't execute C compiler"
29 foreach src [lsort [glob -nocomplain $srcdir/$subdir/*.\[csS\]]] {
30 # If we don't have a compiler available, skip tests :(.
31 if { $has_cpp == 0 && [string match "*.S" $src] } {
35 if { $has_cc == 0 && [string match "*.c" $src] } {
40 # If we're only testing specific files and this isn't one of them,
42 if ![runtest_file_p $runtests $src] {
45 run_sim_test $src $all_machs