-
Notifications
You must be signed in to change notification settings - Fork 91
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
spf run example/TestArray.java encounter exception #4
Comments
Hi, Regarding your first issue, how are you executing TestArray.java? It seems that you are missing the actual definition of the native method getSolvedPC, can you make sure that Java has access to the JNI methods in peers/gov/nasa/jpf/symbc ? About the second issue, the range of integers is constrained in the configuration file (TestArray.jpf): you have This tells the solvers to only consider integers in this range. Depending on your needs, you can either increase the range by setting max_int to 1000, and completely remove these constraints. |
Hi,
|
Hi:
1: When I run spf examples/TestArray.java it occured exception,details is:
Exception in thread "main" java.lang.UnsatisfiedLinkError: gov.nasa.jpf.symbc.Debug.printPC(Ljava/lang/String;)V
at gov.nasa.jpf.symbc.Debug.printPC(Native Method)
2: But when I Verify TestArray.jpf,it can run.But it can't handle
arrList.get(x)_
== 9 and can't generate x<10 [testcase.] How can I know how it handle the library call and How can I look the constraints to help me understand the errorRESULTS is:
Contents of arr:
0 1 2 3 4 5 6 7 8 9 --------->property violated
pc 1 constraint # = 1
x >= 10
=================== Method Sequences
[(expected = java.lang.IndexOutOfBoundsException.class), testarray.testArrayList(10);, ##EXCEPTION## "java.lang.IndexOutOfBoundsException: Index: 0, Size: 10..."]
So am I doing any things wrong? Thank you.
TestArray.jpf:
target=TestArray classpath=${jpf-symbc}/build/examples sourcepath=${jpf-symbc}/src/examples symbolic.method =TestArray.testArrayList(sym) symbolic.min_int=-100 symbolic.max_int=100 #symbolic.dp=z3 #vm.storage.class=nil #listener = .symbc.SymbolicListener #listener = .listener.ChoiceTracker listener = gov.nasa.jpf.symbc.sequences.SymbolicSequenceListener
The text was updated successfully, but these errors were encountered: