-
Notifications
You must be signed in to change notification settings - Fork 76
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
Error occured when using the instrumented jdk #211
Comments
It looks like you are attempting to run Maven itself with Phosphor (Maven is a Java program). This should be supported, but you'll need to pass the flags to enable the java agent when invoking maven. |
I want to use maven with instrumented jre to compile my code. when i used 0.1.0-dev (https://github.com/gmu-swe/phosphor/tree/phosphor-0.1.0-dev), this issue will not happen. How to pass the flags to enable the java agent when invoking maven? I tried |
You can pass arguments to the JVM used by Maven using the
|
I see. We are still fighting a lot of compatibility issues with Phosphor's instrumentation and the many different flavors of OpenJDK 16+. If you are able to run your application under Java 8, you will find the greatest compatibility using the branch |
Thanks! I saw there's a same issue with #203 , but there's no solution. |
You can't use the same command for the older Phosphor - you have to also add the |
Thanks, Dr. Jon! It works after adding this argument. (JDK1.8.0_392 and Phosphor-0.0.5, works with maven 3.8.8 but fails with maven 3.9.6) |
I recently found that The Maven still crashes if I use control flow tracking instrumented jdk. I tried Phosphor-0.0.5 with mvn 3.8.8, 3.9.5 and 3.9.9, all of them fail when initialize the mvn command. The error log is too long, can be reproduced by just mvn -version |
Would you please try using a version of maven prior to 3.6.3? |
Thanks for the reply. mvn 3.6.3 still not works well when executing Also, even when i tried control tracking phosphor just by command, some verification errors often occurred, and the error log always show the different reason, some are related to register. Is that normal? I' not 100% sure if this is caused by my code or Phosphor. Does the version after 0.0.5 improve the compatibility of control tracking? |
It is very challenging to support newer versions of Java with Phosphor. Hence, I am able to offer to help with basic troubleshooting, but development for this project is effectively in retirement right now. It is not normal to receive VerifyError exceptions. Without knowing what your code is (but guessing that you are writing some other instrumentation to integrate with Phosphor, based on your issue #212 ), it is extremely challengintg to offer insights or suggestions on how to move forward. |
Hi all,
I used maven 3.9.6 and openjdk-11.0.21 downloaded from adoptium.
uname -a Linux c83a8f293b33 6.2.0-36-generic #37~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon Oct 9 15:34:04 UTC 2 x86_64 x86_64 x86_64 GNU/Linux (a new docker container, dockerfile: https://github.com/Yhcrown/zsh-in-docker/blob/master/Dockerfile)
here's the command:
mvn install --- Build Success
java -jar phosphor-driver.jar <jdk-11.0.21> --- finished instrumented (no error occured)
But when I changed the JAVA_HOME to the instrumented jdk directory, mvn command did not work:
I tried using jdk16, jdk17 and maven 3.8.8.
They all failed when i used the command mvn after changing the JAVA_HOME
Thanks for your help!
The text was updated successfully, but these errors were encountered: