I use SPEC as a tool to measure java
files running time.
I'm using SPEC2008 which can be downloaded here.
I installed spec2008 (java -jar SPECjvm2008_1_01_setup.jar
) and ran it (java -jar SPECjvm2008.jar
as written in the README file).
I got a results file and a report that everything completed successfully.
Now i need to examine how some changes affect SPEC's running time.
I made the changes in some of SPEC'S files (the java files inside the following folders: compiler
,compress
,crypto
,derby
).
Now i can't run it again using java -jar SPECjvm2008.jar
because the changes i made include jomp
commands (\\omp parallel for
and such). [JOMP is OpenMP for JAVA]
To compile files with such commands i used to do the following:
First, download JOMP. Then:
change
.java
extension to.jomp
. Then type:java jomp.compiler.Jomp MyFile
(now i got a .java
file)
compile to
.class
:javac -classpath YourJompDownloadPath\jomp1.0b.jar; MyFile.java
java -Djomp.threads=n MyPackage.MyFile
So i can't do this now because:
- There are too many files and it would take time changing all extensions to
.jomp
- There are too many files and i need to run all of them as a whole (just as SPEC does), but in
JOMP
commands i only know how to run each file independently.
If there's a workaround for #2 then i'll do #1 manually. So i'm especially looking for a solution/workaround for #2.
edit:
OK so i made a .BAT
file only for step 1 (see method here) because it seems that SPEC has only .java
files so i'll provide it with .java
files only. For the 2nd step i think i need to just run SPEC (java -jar SPECjvm2008.jar
). For the 3rd step, i think instead of normally running SPEC, i need to run it with the parameters in step 3 (Djomp.threads
). That is:
java -Djomp.threads=n -jar SPECjvm2008.jar
Now there's a new problem. I get the warning:
Recompile with -Xlint:unchecked for details
Which was addressed here. But in that link it's run with javac
and not java
. javac
doesn't recognize the parameter Djomp.threads
(and java
doesn't recognize Xlint
). So i think i'm looking for a way to run a .jar
file while using Djomp.threads
and Xlint
.
Note: running the .jar
file SPECjvm2008.jar eventually runs the java
files i need. That's why i said "i'm looking for a way to run a .jar
file..."