mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-08-06 14:49:38 +08:00
sim: testsuite: initial support for OS-specific tests
We usually test against the newlib/libgloss environment, but for a few ports that also support Linux apps, we want to test that logic too. A lot of the C code is written such that it works with either newlib/libgloss or glibc/linux toolchains, but we have some tests that end up being Linux-specific. Cris has been using the target tuple as a rough proxy for this (where cris*-*-elf is assumed to be newlib/libgloss, and everything else is glibc/linux), but that is a bit too rough, and it doesn't work in a multitarget build. So lets create a few stub files that we can do compile tests with to detect the different setups, and then let tests declare which one they require (if they require any at all).
This commit is contained in:
@ -1,5 +1,5 @@
|
|||||||
/* Check access(2) trivially. Newlib doesn't have it.
|
/* Check access(2) trivially. Newlib doesn't have it.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: *: could not load ELF interpreter `*' for program `*'\n
|
#output: *: could not load ELF interpreter `*' for program `*'\n
|
||||||
*/
|
*/
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#cc: additional_flags=-Wl,-dynamic-linker,/dev/null
|
#cc: additional_flags=-Wl,-dynamic-linker,/dev/null
|
||||||
#output: *: could not load ELF interpreter `*' for program `*'\n
|
#output: *: could not load ELF interpreter `*' for program `*'\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#cc: additional_flags=-Wl,-dynamic-linker,/compilercheck.x
|
#cc: additional_flags=-Wl,-dynamic-linker,/compilercheck.x
|
||||||
#sim: --sysroot=$pwd
|
#sim: --sysroot=$pwd
|
||||||
|
@ -34,6 +34,7 @@ if [istarget cris*-*-elf] {
|
|||||||
|
|
||||||
# Using target_compile, since it is less noisy,
|
# Using target_compile, since it is less noisy,
|
||||||
global global_cc_works
|
global global_cc_works
|
||||||
|
global global_cc_os
|
||||||
if { $global_cc_works == 1 } {
|
if { $global_cc_works == 1 } {
|
||||||
# Now check if we can link a program dynamically, and where
|
# Now check if we can link a program dynamically, and where
|
||||||
# libc.so is located. If it is, we provide a sym link to the
|
# libc.so is located. If it is, we provide a sym link to the
|
||||||
@ -103,6 +104,7 @@ foreach src [lsort [glob -nocomplain $srcdir/$subdir/*.c]] {
|
|||||||
set opts(sim) ""
|
set opts(sim) ""
|
||||||
set opts(output) ""
|
set opts(output) ""
|
||||||
set opts(progoptions) ""
|
set opts(progoptions) ""
|
||||||
|
set opts(progos) ""
|
||||||
set opts(timeout) ""
|
set opts(timeout) ""
|
||||||
set opts(mach) ""
|
set opts(mach) ""
|
||||||
set opts(xerror) "no"
|
set opts(xerror) "no"
|
||||||
@ -164,6 +166,11 @@ foreach src [lsort [glob -nocomplain $srcdir/$subdir/*.c]] {
|
|||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if { $opts(progos) != "" && $opts(progos) != $global_cc_os } {
|
||||||
|
untested $testname
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
# If no machine specific options, default to the general version.
|
# If no machine specific options, default to the general version.
|
||||||
if ![info exists opts(sim,$mach)] {
|
if ![info exists opts(sim,$mach)] {
|
||||||
set opts(sim,$mach) $opts(sim)
|
set opts(sim,$mach) $opts(sim)
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#output: got: a\nthen: bc\nexit: 0\n
|
#output: got: a\nthen: bc\nexit: 0\n
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Make sure the thread system trivially works with trace output.
|
/* Make sure the thread system trivially works with trace output.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-trace=basic --trace-file=$pwd/clone2.tmp
|
#sim: --cris-trace=basic --trace-file=$pwd/clone2.tmp
|
||||||
#output: got: a\nthen: bc\nexit: 0\n
|
#output: got: a\nthen: bc\nexit: 0\n
|
||||||
*/
|
*/
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that exiting from a parent thread does not kill the child.
|
/* Check that exiting from a parent thread does not kill the child.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens when we reach the #threads implementation limit.
|
/* Check that TRT happens when we reach the #threads implementation limit.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that unimplemented clone syscalls get the right treatment.
|
/* Check that unimplemented clone syscalls get the right treatment.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented clone syscall *
|
#output: Unimplemented clone syscall *
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Compiler options:
|
/* Compiler options:
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#output: Starting process a\naaaaaaaaStarting process b\nababbbbbbbbb
|
#output: Starting process a\naaaaaaaaStarting process b\nababbbbbbbbb
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/* Check exit_group(2) trivially. Newlib doesn't have it and the
|
/* Check exit_group(2) trivially. Newlib doesn't have it and the
|
||||||
pre-v32 glibc requires updated headers we'd have to check or adjust
|
pre-v32 glibc requires updated headers we'd have to check or adjust
|
||||||
for.
|
for.
|
||||||
#notarget: cris-*-* *-*-elf
|
#progos: linux
|
||||||
#output: exit_group\n
|
#output: exit_group\n
|
||||||
*/
|
*/
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check exit_group(2) trivially with non-zero status.
|
/* Check exit_group(2) trivially with non-zero status.
|
||||||
#notarget: cris-*-* *-*-elf
|
#progos: linux
|
||||||
#output: exit_group\n
|
#output: exit_group\n
|
||||||
#xerror:
|
#xerror:
|
||||||
*/
|
*/
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that we get the expected message for unsupported fcntl calls.
|
/* Check that we get the expected message for unsupported fcntl calls.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented fcntl*
|
#output: Unimplemented fcntl*
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that the ftruncate syscall works trivially.
|
/* Check that the ftruncate syscall works trivially.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Check that we get a proper error indication if trying ftruncate on a
|
/* Check that we get a proper error indication if trying ftruncate on a
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
works. Jump through a few hoops to avoid reading the host
|
works. Jump through a few hoops to avoid reading the host
|
||||||
ld.so.cache (having no absolute path specified for the executable
|
ld.so.cache (having no absolute path specified for the executable
|
||||||
falls back on loading through the same mechanisms as a DSO).
|
falls back on loading through the same mechanisms as a DSO).
|
||||||
#notarget: *-*-elf
|
#progos: linux
|
||||||
#sim: --sysroot=$pwd $pwd/lib/ld.so.1 --library-path /
|
#sim: --sysroot=$pwd $pwd/lib/ld.so.1 --library-path /
|
||||||
*/
|
*/
|
||||||
#include "hello.c"
|
#include "hello.c"
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define _GNU_SOURCE
|
#define _GNU_SOURCE
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define _GNU_SOURCE
|
#define _GNU_SOURCE
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define _GNU_SOURCE
|
#define _GNU_SOURCE
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Just check that MAP_DENYWRITE is "honored" (ignored).
|
/* Just check that MAP_DENYWRITE is "honored" (ignored).
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
#define MMAP_FLAGS (MAP_PRIVATE|MAP_DENYWRITE)
|
#define MMAP_FLAGS (MAP_PRIVATE|MAP_DENYWRITE)
|
||||||
#include "mmap1.c"
|
#include "mmap1.c"
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define _GNU_SOURCE
|
#define _GNU_SOURCE
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* Check that mmapping specifying a previously mmapped address without
|
/* Check that mmapping specifying a previously mmapped address without
|
||||||
MAP_FIXED works; that we just don't get the same address.
|
MAP_FIXED works; that we just don't get the same address.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
#define NO_MUNMAP
|
#define NO_MUNMAP
|
||||||
#define MMAP_FLAGS2 MAP_PRIVATE
|
#define MMAP_FLAGS2 MAP_PRIVATE
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/* Check that mmapping a page-aligned size, larger than the file,
|
/* Check that mmapping a page-aligned size, larger than the file,
|
||||||
works.
|
works.
|
||||||
|
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Make sure we get an address where the size fits. */
|
/* Make sure we get an address where the size fits. */
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* Check that mmapping 0 using MAP_FIXED works, both with/without
|
/* Check that mmapping 0 using MAP_FIXED works, both with/without
|
||||||
there being previously mmapped contents.
|
there being previously mmapped contents.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
#define MMAP_FLAGS1 MAP_PRIVATE | MAP_ANONYMOUS | MAP_FIXED
|
#define MMAP_FLAGS1 MAP_PRIVATE | MAP_ANONYMOUS | MAP_FIXED
|
||||||
#define NO_MUNMAP
|
#define NO_MUNMAP
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check unimplemented-output for mprotect call.
|
/* Check unimplemented-output for mprotect call.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented mprotect call (0x0, 0x2001, 0x4)\n
|
#output: Unimplemented mprotect call (0x0, 0x2001, 0x4)\n
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens when error on too many opened files.
|
/* Check that TRT happens when error on too many opened files.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --sysroot=$pwd
|
#sim: --sysroot=$pwd
|
||||||
*/
|
*/
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check for proper pipe semantics at corner cases.
|
/* Check for proper pipe semantics at corner cases.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that closing a pipe with a nonempty buffer works.
|
/* Check that closing a pipe with a nonempty buffer works.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#output: got: a\ngot: b\nexit: 0\n
|
#output: got: a\ngot: b\nexit: 0\n
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens when error on pipe call.
|
/* Check that TRT happens when error on pipe call.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens for pipe corner cases.
|
/* Check that TRT happens for pipe corner cases.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens for pipe corner cases (for our definition of TRT).
|
/* Check that TRT happens for pipe corner cases (for our definition of TRT).
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Terminating simulation due to writing pipe * from one single thread\n
|
#output: Terminating simulation due to writing pipe * from one single thread\n
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that writing an inordinate amount of data works (somewhat).
|
/* Check that writing an inordinate amount of data works (somewhat).
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#output: got: a\nexit: 0\n
|
#output: got: a\nexit: 0\n
|
||||||
This test-case will *not* work on host (or for real): the first
|
This test-case will *not* work on host (or for real): the first
|
||||||
pipemax+1 bytes will be successfully written. It's just for
|
pipemax+1 bytes will be successfully written. It's just for
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check for proper pipe semantics at corner cases.
|
/* Check for proper pipe semantics at corner cases.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that odd cases of readlink work.
|
/* Check that odd cases of readlink work.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As readlink5.c (sic), but specifying silent ENOSYS.
|
/* As readlink5.c (sic), but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet --argv0 ./readlink11.c.x
|
#sim: --cris-unknown-syscall=enosys-quiet --argv0 ./readlink11.c.x
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Simulator options:
|
/* Simulator options:
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --sysroot=$pwd
|
#sim: --sysroot=$pwd
|
||||||
*/
|
*/
|
||||||
#define SYSROOTED 1
|
#define SYSROOTED 1
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check for corner case: readlink of too-long name.
|
/* Check for corner case: readlink of too-long name.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that unsupported readlink calls don't cause the simulator to abort.
|
/* Check that unsupported readlink calls don't cause the simulator to abort.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --argv0 ./readlink5.c.x
|
#sim: --argv0 ./readlink5.c.x
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented readlink syscall (*)\n
|
#output: Unimplemented readlink syscall (*)\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that rare readlink calls don't cause the simulator to abort.
|
/* Check that rare readlink calls don't cause the simulator to abort.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --argv0 $pwd/readlink6.c.x
|
#sim: --argv0 $pwd/readlink6.c.x
|
||||||
*/
|
*/
|
||||||
#include "readlink2.c"
|
#include "readlink2.c"
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that rare readlink calls don't cause the simulator to abort.
|
/* Check that rare readlink calls don't cause the simulator to abort.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --env-unset PWD
|
#sim: --env-unset PWD
|
||||||
*/
|
*/
|
||||||
#include "readlink2.c"
|
#include "readlink2.c"
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that rare readlink calls don't cause the simulator to abort.
|
/* Check that rare readlink calls don't cause the simulator to abort.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --sysroot=$pwd --env-unset PWD
|
#sim: --sysroot=$pwd --env-unset PWD
|
||||||
*/
|
*/
|
||||||
#define SYSROOTED 1
|
#define SYSROOTED 1
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that odd cases of readlink work.
|
/* Check that odd cases of readlink work.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-DX="$pwd"
|
#cc: additional_flags=-DX="$pwd"
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Compiler options:
|
/* Compiler options:
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented rt_sigprocmask syscall (0x3, 0x0, 0x3dff*\n
|
#output: Unimplemented rt_sigprocmask syscall (0x3, 0x0, 0x3dff*\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Test that TRT happens for invalid rt_sigsuspend calls. Single-thread.
|
/* Test that TRT happens for invalid rt_sigsuspend calls. Single-thread.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented rt_sigsuspend syscall arguments (0x1, 0x2)\n
|
#output: Unimplemented rt_sigsuspend syscall arguments (0x1, 0x2)\n
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sched.h>
|
#include <sched.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sched.h>
|
#include <sched.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sched.h>
|
#include <sched.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sched.h>
|
#include <sched.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sched.h>
|
#include <sched.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sched.h>
|
#include <sched.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check corner error case: specifying invalid PID.
|
/* Check corner error case: specifying invalid PID.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sched.h>
|
#include <sched.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check corner error case: specifying invalid PID.
|
/* Check corner error case: specifying invalid PID.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <sched.h>
|
#include <sched.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check corner error case: specifying invalid scheduling policy.
|
/* Check corner error case: specifying invalid scheduling policy.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sched.h>
|
#include <sched.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check corner error case: specifying unimplemented resource.
|
/* Check corner error case: specifying unimplemented resource.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
#include <sys/time.h>
|
#include <sys/time.h>
|
||||||
#include <sys/resource.h>
|
#include <sys/resource.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that the syscall set_thread_area is supported and does the right thing.
|
/* Check that the syscall set_thread_area is supported and does the right thing.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens when trying to IGN an non-ignorable signal, more than one thread.
|
/* Check that TRT happens when trying to IGN an non-ignorable signal, more than one thread.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Exiting pid 42 due to signal 9\n
|
#output: Exiting pid 42 due to signal 9\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens when getting a non-standard (realtime) signal, more than one thread.
|
/* Check that TRT happens when getting a non-standard (realtime) signal, more than one thread.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented signal: 77\n
|
#output: Unimplemented signal: 77\n
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* Check that TRT happens for a signal sent to a non-existent process/thread, more than one thread.
|
/* Check that TRT happens for a signal sent to a non-existent process/thread, more than one thread.
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens at an abort (3) call, more than one thread.
|
/* Check that TRT happens at an abort (3) call, more than one thread.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Exiting pid 42 due to signal 6\n
|
#output: Exiting pid 42 due to signal 6\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens at an non-abort non-caught signal, more than one thread.
|
/* Check that TRT happens at an non-abort non-caught signal, more than one thread.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Exiting pid 42 due to signal 7\n
|
#output: Exiting pid 42 due to signal 7\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check unsupported case of sigaction syscall.
|
/* Check unsupported case of sigaction syscall.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented rt_sigaction syscall (0x8, 0x3df*\n
|
#output: Unimplemented rt_sigaction syscall (0x8, 0x3df*\n
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens at an non-abort ignored signal, more than one thread.
|
/* Check that TRT happens at an non-abort ignored signal, more than one thread.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Test that TRT happens for spurious sigreturn calls. Single-thread.
|
/* Test that TRT happens for spurious sigreturn calls. Single-thread.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Invalid sigreturn syscall: no signal handler active (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
#output: Invalid sigreturn syscall: no signal handler active (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that TRT happens for spurious sigreturn calls. Multiple threads.
|
/* Check that TRT happens for spurious sigreturn calls. Multiple threads.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Invalid sigreturn syscall: no signal handler active (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
#output: Invalid sigreturn syscall: no signal handler active (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Simulator options:
|
/* Simulator options:
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --sysroot=$pwd
|
#sim: --sysroot=$pwd
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that lstat:ing an nonexistent file works as expected.
|
/* Check that lstat:ing an nonexistent file works as expected.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* For this test, we need to do the lstat syscall directly, or else
|
/* For this test, we need to do the lstat syscall directly, or else
|
||||||
glibc gets a SEGV.
|
glibc gets a SEGV.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Test unknown-syscall output.
|
/* Test unknown-syscall output.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented syscall: 166 (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
#output: Unimplemented syscall: 166 (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Test unknown-syscall output.
|
/* Test unknown-syscall output.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented syscall: 0 (0x3, 0x2, 0x1, 0x4, 0x6, 0x5)\n
|
#output: Unimplemented syscall: 0 (0x3, 0x2, 0x1, 0x4, 0x6, 0x5)\n
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, just actually specifying the default.
|
/* As the included file, just actually specifying the default.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=stop
|
#sim: --cris-unknown-syscall=stop
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented syscall: 166 (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
#output: Unimplemented syscall: 166 (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, just actually specifying the default.
|
/* As the included file, just actually specifying the default.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=stop
|
#sim: --cris-unknown-syscall=stop
|
||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented syscall: 0 (0x3, 0x2, 0x1, 0x4, 0x6, 0x5)\n
|
#output: Unimplemented syscall: 0 (0x3, 0x2, 0x1, 0x4, 0x6, 0x5)\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying ENOSYS with message.
|
/* As the included file, but specifying ENOSYS with message.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys
|
#sim: --cris-unknown-syscall=enosys
|
||||||
#output: Unimplemented syscall: 166 (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
#output: Unimplemented syscall: 166 (0x1, 0x2, 0x3, 0x4, 0x5, 0x6)\n
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying ENOSYS with message.
|
/* As the included file, but specifying ENOSYS with message.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys
|
#sim: --cris-unknown-syscall=enosys
|
||||||
#output: Unimplemented syscall: 0 (0x3, 0x2, 0x1, 0x4, 0x6, 0x5)\n
|
#output: Unimplemented syscall: 0 (0x3, 0x2, 0x1, 0x4, 0x6, 0x5)\n
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
#xerror:
|
#xerror:
|
||||||
#output: Unimplemented _sysctl syscall *\n
|
#output: Unimplemented _sysctl syscall *\n
|
||||||
#output: program stopped with signal 4 (*).\n
|
#output: program stopped with signal 4 (*).\n
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* As the included file, but specifying silent ENOSYS.
|
/* As the included file, but specifying silent ENOSYS.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#sim: --cris-unknown-syscall=enosys-quiet
|
#sim: --cris-unknown-syscall=enosys-quiet
|
||||||
#output: ENOSYS\n
|
#output: ENOSYS\n
|
||||||
#output: xyzzy\n
|
#output: xyzzy\n
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* Compiler options:
|
/* Compiler options:
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
|
|
||||||
A sanity check for syscalls resulting from
|
A sanity check for syscalls resulting from
|
||||||
pthread_getschedparam and pthread_setschedparam. */
|
pthread_getschedparam and pthread_setschedparam. */
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* Compiler options:
|
/* Compiler options:
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
|
|
||||||
To test sched_yield in the presencs of threads. Core from ex1.c. */
|
To test sched_yield in the presencs of threads. Core from ex1.c. */
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Compiler options:
|
/* Compiler options:
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#output: abb ok\n
|
#output: abb ok\n
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Compiler options:
|
/* Compiler options:
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
#cc: additional_flags=-pthread
|
#cc: additional_flags=-pthread
|
||||||
#output: abbb ok\n
|
#output: abbb ok\n
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Check that the truncate syscall works trivially.
|
/* Check that the truncate syscall works trivially.
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/*
|
/*
|
||||||
#sim: --sysroot=$pwd
|
#sim: --sysroot=$pwd
|
||||||
#notarget: cris*-*-elf
|
#progos: linux
|
||||||
*/
|
*/
|
||||||
#define PREFIX "/"
|
#define PREFIX "/"
|
||||||
#include "truncate1.c"
|
#include "truncate1.c"
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user