ET2/JVM runs correctly (sometimes) and without thrown exceptions on Oracle Java 8 if bytecode verification is disabled, but it seems to sometimes fail bytecode verification at the moment. Currently we are not exactly sure what is wrong with it.
- JNIF, available from here.
- Java 8
- For the trace analysis programs:
- gcc/g++ or clang++ (TODO: Which versions did we use?)
- cmake 3.9 or greater
One must modify the JNIF file src-libjnif/parser.cpp and go into the AttrsParser::parse
method to prevent the parsing of LineNumberTable, LocalVariableTable and LocalVariableTypeTable, or
use our fork of JNIF.
- cmake is many things, but most importantly it's a Makefile generator.
- Steps to building with
cmake:- Create a
BUILDdirectory anywhere.mkdir /path/to/et2-agent/BUILD
- Run
cmakeonCMakeLists.txtcmake /path/to/et2-java/ -DLIBJNIF=/path/to/jnif/src-libjnif -DJAVA_HOME=/path/to/java -DBOOST_ROOT=/path/to/boost_1.66
- This generates a
Makefilein/path/to/BUILDcd /path/to/BUILD && make
- Create a
- Steps to building with
cmake:- Create a
BUILDdirectory anywhere.mkdir /path/to/et2-simulator/BUILD
- Run
cmakeonCMakeLists.txt- `cmake /path/to/et2-simulator
- This generates a
Makefilein/path/to/et2-simulator/BUILDcd /path/to/et2-simulator/BUILD && make
- Create a
- The tests are run using pytest.
- See the et2_tests.py for details.
- Use the following command:
python3.4 -m pytest et2_tests.py --java_path /etc/alternatives/java_sdk_1.8.0/bin/java --agent_path /data/rveroy/pulsrc/et2-java/BUILD --rootdir .- Add
-vto the end of the command to get verbose testing.
- Modify
--java_pathand--agent_pathto fit your setup. - The
--rootdiroption specifies where the pytest cache is placed.
- Ensure
JAVA_HOMEis set correctly - Set the variables in
Makefile.inc make- Note: this is deprecated. Please see how to build with cmake.
make testjava -agentlib:et2 Hellojava -agentlib:et2 BinarySearchTree