Mercurial > hg > truffle
comparison test/runtime/6888954/vmerrors.sh @ 11092:59b052799158
8015884: runThese crashed with SIGSEGV, hs_err has an error instead of stacktrace
Summary: Dl_info struct should only be used if dladdr() has returned non-zero (no errors) and always check the dladdr() return value; Dl_info.dli_sname and Dl_info.dli_saddr fields should only be used if non-NULL; update/improve runtime/6888954/vmerrors.sh test
Reviewed-by: dsamersoff, zgu, hseigel, coleenp
author | dcubed |
---|---|
date | Thu, 04 Jul 2013 21:10:17 -0700 |
parents | 5b77884bd4b7 |
children | cc4f5f8d885e |
comparison
equal
deleted
inserted
replaced
11091:a55aa67bce1a | 11092:59b052799158 |
---|---|
1 # @test | 1 # @test |
2 # @bug 6888954 | 2 # @bug 6888954 |
3 # @bug 8015884 | |
3 # @summary exercise HotSpot error handling code | 4 # @summary exercise HotSpot error handling code |
4 # @author John Coomes | 5 # @author John Coomes |
5 # @run shell vmerrors.sh | 6 # @run shell vmerrors.sh |
6 | 7 |
7 # Repeatedly invoke java with a command-line option that causes HotSpot to | 8 # Repeatedly invoke java with a command-line option that causes HotSpot to |
25 | 26 |
26 i=1 | 27 i=1 |
27 rc=0 | 28 rc=0 |
28 | 29 |
29 assert_re='(assert|guarantee)[(](str|num).*failed: *' | 30 assert_re='(assert|guarantee)[(](str|num).*failed: *' |
31 # for bad_data_ptr_re: | |
32 # EXCEPTION_ACCESS_VIOLATION - Win-* | |
33 # SIGILL - MacOS X | |
34 # SIGSEGV - Linux-*, Solaris SPARC-*, Solaris X86-* | |
35 # | |
36 bad_data_ptr_re='(SIGILL|SIGSEGV|EXCEPTION_ACCESS_VIOLATION).* at pc=' | |
37 # | |
38 # for bad_func_ptr_re: | |
39 # EXCEPTION_ACCESS_VIOLATION - Win-* | |
40 # SIGBUS - Solaris SPARC-64 | |
41 # SIGSEGV - Linux-*, Solaris SPARC-32, Solaris X86-* | |
42 # | |
43 # Note: would like to use "pc=0x00*0f," in the pattern, but Solaris SPARC-* | |
44 # gets its signal at a PC in test_error_handler(). | |
45 # | |
46 bad_func_ptr_re='(SIGBUS|SIGSEGV|EXCEPTION_ACCESS_VIOLATION).* at pc=' | |
30 guarantee_re='guarantee[(](str|num).*failed: *' | 47 guarantee_re='guarantee[(](str|num).*failed: *' |
31 fatal_re='fatal error: *' | 48 fatal_re='fatal error: *' |
32 signal_re='(SIGSEGV|EXCEPTION_ACCESS_VIOLATION).* at pc=' | |
33 tail_1='.*expected null' | 49 tail_1='.*expected null' |
34 tail_2='.*num=' | 50 tail_2='.*num=' |
35 | 51 |
36 for re in \ | 52 for re in \ |
37 "${assert_re}${tail_1}" "${assert_re}${tail_2}" \ | 53 "${assert_re}${tail_1}" "${assert_re}${tail_2}" \ |
38 "${guarantee_re}${tail_1}" "${guarantee_re}${tail_2}" \ | 54 "${guarantee_re}${tail_1}" "${guarantee_re}${tail_2}" \ |
39 "${fatal_re}${tail_1}" "${fatal_re}${tail_2}" \ | 55 "${fatal_re}${tail_1}" "${fatal_re}${tail_2}" \ |
40 "${fatal_re}.*truncated" "ChunkPool::allocate" \ | 56 "${fatal_re}.*truncated" "ChunkPool::allocate" \ |
41 "ShouldNotCall" "ShouldNotReachHere" \ | 57 "ShouldNotCall" "ShouldNotReachHere" \ |
42 "Unimplemented" "$signal_re" | 58 "Unimplemented" "$bad_data_ptr_re" \ |
43 | 59 "$bad_func_ptr_re" |
60 | |
44 do | 61 do |
45 i2=$i | 62 i2=$i |
46 [ $i -lt 10 ] && i2=0$i | 63 [ $i -lt 10 ] && i2=0$i |
47 | 64 |
48 "$TESTJAVA/bin/java" $TESTVMOPTS -XX:+IgnoreUnrecognizedVMOptions \ | 65 "$TESTJAVA/bin/java" $TESTVMOPTS -XX:+IgnoreUnrecognizedVMOptions \ |