Unfortunately, on the real system, I found another problem soon after. It does not seem to be related to MJIEnv anymore, though. It also works on small examples but not on the real system so I currently don't have a test case.
The issue is a private field inside a public class, which is accessed (set) by another class using reflection (Field.setInt). The type is correct this time but the "frozen" information is incorrect (the field is not final). The field is declared as "private int ..." in a public class.
[SEVERE] JPF exception, terminating: exception in native method java.lang.reflect.Field.setInt
---------------------- JPF error stack trace ---------------------
gov.nasa.jpf.JPFException: attempt to modify frozen object: ...
at gov.nasa.jpf.vm.ElementInfo.checkIsModifiable(ElementInfo.java:2100)
at gov.nasa.jpf.vm.ElementInfo.setIntField(ElementInfo.java:876)
at gov.nasa.jpf.vm.JPF_java_lang_reflect_Field.setInt__Ljava_lang_Object_2I__V(JPF_java_lang_reflect_Field.java:291)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at gov.nasa.jpf.vm.NativeMethodInfo.executeNative(NativeMethodInfo.java:121)
at gov.nasa.jpf.jvm.bytecode.EXECUTENATIVE.execute(EXECUTENATIVE.java:71)
at gov.nasa.jpf.vm.ThreadInfo.executeInstruction(ThreadInfo.java:1894)
at gov.nasa.jpf.vm.ThreadInfo.executeTransition(ThreadInfo.java:1845)
at gov.nasa.jpf.vm.SystemState.executeNextTransition(SystemState.java:748)
at gov.nasa.jpf.vm.VM.forward(VM.java:1638)
at gov.nasa.jpf.search.Search.forward(Search.java:533)
at gov.nasa.jpf.search.DFSearch.search(DFSearch.java:78)
at gov.nasa.jpf.JPF.run(JPF.java:613)
at gov.nasa.jpf.JPF.start(JPF.java:190)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at gov.nasa.jpf.tool.Run.call(Run.java:76)
at gov.nasa.jpf.tool.RunJPF.main(RunJPF.java:117)
---------------------- JPF error stack trace ---------------------
gov.nasa.jpf.JPFNativePeerException: exception in native method java.lang.reflect.Field.setInt
at gov.nasa.jpf.vm.NativeMethodInfo.executeNative(NativeMethodInfo.java:179)
at gov.nasa.jpf.jvm.bytecode.EXECUTENATIVE.execute(EXECUTENATIVE.java:71)
at gov.nasa.jpf.vm.ThreadInfo.executeInstruction(ThreadInfo.java:1894)
at gov.nasa.jpf.vm.ThreadInfo.executeTransition(ThreadInfo.java:1845)
at gov.nasa.jpf.vm.SystemState.executeNextTransition(SystemState.java:748)
at gov.nasa.jpf.vm.VM.forward(VM.java:1638)
at gov.nasa.jpf.search.Search.forward(Search.java:533)
at gov.nasa.jpf.search.DFSearch.search(DFSearch.java:78)
at gov.nasa.jpf.JPF.run(JPF.java:613)
at gov.nasa.jpf.JPF.start(JPF.java:190)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at gov.nasa.jpf.tool.Run.call(Run.java:76)
at gov.nasa.jpf.tool.RunJPF.main(RunJPF.java:117)
Caused by: gov.nasa.jpf.JPFException: attempt to modify frozen object: ...
at gov.nasa.jpf.vm.ElementInfo.checkIsModifiable(ElementInfo.java:2100)
at gov.nasa.jpf.vm.ElementInfo.setIntField(ElementInfo.java:876)
at gov.nasa.jpf.vm.JPF_java_lang_reflect_Field.setInt__Ljava_lang_Object_2I__V(JPF_java_lang_reflect_Field.java:291)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at gov.nasa.jpf.vm.NativeMethodInfo.executeNative(NativeMethodInfo.java:121)
... 15 more