Mercurial > hg > truffle
annotate test/runtime/7020373/Test7020373.sh @ 6236:950ed41429e5
Merge
author | zgu |
---|---|
date | Thu, 19 Jul 2012 06:24:46 -0700 |
parents | 149c36689fcb |
children | fe94b4e7212b |
rev | line source |
---|---|
3862
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
1 #!/bin/sh |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
2 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
3 ## |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
4 ## @test |
6230
149c36689fcb
7053586: TEST: runtime/7020373/Test7020373.sh fails on 64-bit platforms
asaha
parents:
6074
diff
changeset
|
5 ## @bug 7020373 7055247 7053586 |
3862
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
6 ## @key cte_test |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
7 ## @summary JSR rewriting can overflow memory address size variables |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
8 ## @run shell Test7020373.sh |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
9 ## |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
10 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
11 if [ "${TESTSRC}" = "" ] |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
12 then TESTSRC=. |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
13 fi |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
14 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
15 if [ "${TESTJAVA}" = "" ] |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
16 then |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
17 PARENT=`dirname \`which java\`` |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
18 TESTJAVA=`dirname ${PARENT}` |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
19 echo "TESTJAVA not set, selecting " ${TESTJAVA} |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
20 echo "If this is incorrect, try setting the variable manually." |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
21 fi |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
22 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
23 if [ "${TESTCLASSES}" = "" ] |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
24 then |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
25 echo "TESTCLASSES not set. Test cannot execute. Failed." |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
26 exit 1 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
27 fi |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
28 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
29 # set platform-dependent variables |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
30 OS=`uname -s` |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
31 case "$OS" in |
6230
149c36689fcb
7053586: TEST: runtime/7020373/Test7020373.sh fails on 64-bit platforms
asaha
parents:
6074
diff
changeset
|
32 SunOS | Linux | Darwin ) |
3862
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
33 NULL=/dev/null |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
34 PS=":" |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
35 FS="/" |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
36 ;; |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
37 Windows_* ) |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
38 NULL=NUL |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
39 PS=";" |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
40 FS="\\" |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
41 ;; |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
42 * ) |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
43 echo "Unrecognized system!" |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
44 exit 1; |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
45 ;; |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
46 esac |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
47 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
48 JEMMYPATH=${CPAPPEND} |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
49 CLASSPATH=.${PS}${TESTCLASSES}${PS}${JEMMYPATH} ; export CLASSPATH |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
50 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
51 THIS_DIR=`pwd` |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
52 |
6074
037973617842
7157734: hotspot test scripts not testing 64-bit JVM under JPRT/JTREG.
kevinw
parents:
3863
diff
changeset
|
53 ${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} -version |
3862
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
54 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
55 ${TESTJAVA}${FS}bin${FS}jar xvf ${TESTSRC}${FS}testcase.jar |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
56 |
6074
037973617842
7157734: hotspot test scripts not testing 64-bit JVM under JPRT/JTREG.
kevinw
parents:
3863
diff
changeset
|
57 ${TESTJAVA}${FS}bin${FS}java ${TESTVMOPTS} OOMCrashClass4000_1 > test.out 2>&1 |
3862
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
58 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
59 cat test.out |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
60 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
61 egrep "SIGSEGV|An unexpected error has been detected" test.out |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
62 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
63 if [ $? = 0 ] |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
64 then |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
65 echo "Test Failed" |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
66 exit 1 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
67 else |
6230
149c36689fcb
7053586: TEST: runtime/7020373/Test7020373.sh fails on 64-bit platforms
asaha
parents:
6074
diff
changeset
|
68 egrep "java.lang.LinkageError|java.lang.NoSuchMethodError|Main method not found in class OOMCrashClass4000_1|insufficient memory" test.out |
3862
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
69 if [ $? = 0 ] |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
70 then |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
71 echo "Test Passed" |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
72 exit 0 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
73 else |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
74 echo "Test Failed" |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
75 exit 1 |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
76 fi |
52e4ba46751f
7020373: JSR rewriting can overflow memory address size variables
kamg
parents:
diff
changeset
|
77 fi |