Fixup commit 39b83981 ("Flush icache with __builtin___clear_cache() in
tests when compiling with GCC") to fix compilation with older GCC
versions that do not provide __builtin___clear_cache().
When compiling with GCC, use the builtin instruction cache flushing
mechanism in all tests where it is needed.
Quoting GCC docs: ''If the target does not require instruction cache
flushes, __builtin___clear_cache has no effect. Otherwise either
instructions are emitted in-line to clear the instruction cache or a
call to the __clear_cache function in libgcc is made.''.
Compiling the tests with -Wextra results to lots of warnings for unused
parameters. Annotate these cases with the `unused' attribute to avoid
the warnings.
The testcase tests/Gtest-dyn1.c uses the signal() function and should
therefore include the corresponding header file.
Signed-off-by: Ken Werner <ken.werner@linaro.org>
Define an appropriate fdesc struct and its corresponding accessors that take
care of the thumb marker on ARM. Call the __clear_cache built-in instead of
flush_cache if the GNU compiler is used.
Signed-off-by: Ken Werner <ken.werner@linaro.org>
- Gtest-bt: like on x86/-64, the stack size passed to sigaltstack() is
too small for ARM thus causing segmentation fault due to stack
overflow.
- Gtest-dyn1: code size definition of dynamic function (template()) on
testcase is too big for ARM architecture so memcpy() reads invalid
memory causing random crashes (segmentation fault). A better
solution would be to compile the function in a separate binary,
mmap() it and memcpy() from it instead, so maximum size is known for
sure.
- check-name-space.in: fix some "bashisms", it causes the script to
fail to run on N8XX's busybox shell.
Signed-off-by: Anderson Lizardo <anderson.lizardo@indt.org.br>
Signed-off-by: Bruna Moreira <bruna.moreira@indt.org.br>
* tests/test-ptrace.c (target_pid_kill): New function.
(target_pid, main): TARGET_PID made static, for target_pid_kill ().
(main): Register target_pid_kill () for atexit(3).
2007-04-04 Jan Kratochvil <jan.kratochvil@redhat.com>
* tests/Gtest-dyn1.c, tests/test-async-sig.c, tests/test-ptrace.c:
Fixed lockups on broken libunwind (as ppc64 is).
2007-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
* tests/test-async-sig.c (do_backtrace): Limit maximum backtrace depth
to 100 iterations; it workarounds FC6 DWARF-broken glibc.
2006-12-10 Jan Kratochvil <jan.kratochvil@redhat.com>
* tests/test-ptrace.c (main): Check for too many unexpected child
signals, such as the common `SIGSEGV'.