Skip to content
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 thrown when running with --dump #2

Open
akshayutture opened this issue Sep 29, 2021 · 4 comments
Open

Error thrown when running with --dump #2

akshayutture opened this issue Sep 29, 2021 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@akshayutture
Copy link

akshayutture commented Sep 29, 2021

When running jreduce with --dump on some benchmarks, it throws an error.

The error disappears when the --dump option is removed, but the tool runs too many iterations (450 iterations, ~45minutes, after which the run was manually terminated)

Here is the workfolder
https://drive.google.com/file/d/1aL8GT9vOgRwFWR3ISCa1llCu_Bpudfcf/view?usp=sharing

Here is the error-log.

  • jreduce --work-folder _jreduce/workfolder --cp test.jar --core @test.classes.txt --dump --jre /usr/lib/jvm/java-8-openjdk-amd64/jre -S items+logic --stdlib ../../stdlib.bin -o app+lib.after.jar --timelimit 1800 app+lib.jar -- /home/akshayutture/projects/jdebloat/scripts/predicate.sh /home/akshayutture/projects/jdebloat/output/05/initial+jreduce '{}'
    10:51:21 ├ JReduce
    10:51:21 │ ├ Started JReduce.
    10:51:21 │ ├ Reading inputs
    10:51:21 │ │ └ 0.000s
    10:51:21 │ ├ Calculating Initial Problem
    10:51:21 │ │ ├ setup
    10:51:21 │ │ │ └ 0.054s
    10:51:21 │ │ ├ run
    10:51:22 │ │ │ └ 1.276s
    10:51:22 │ │ └ 1.332s
    10:51:22 │ ├ Refining Problem
    10:51:22 │ │ └ 0.015s
    10:51:22 │ ├ Initializing key function
    10:51:22 │ │ ├ Calculating the hierarchy
    10:51:22 │ │ │ ├ Load stdlib stubs
    10:51:29 │ │ │ │ └ 6.500s
    10:51:29 │ │ │ ├ Load project stubs
    10:51:31 │ │ │ │ └ 1.681s
    10:51:31 │ │ │ ├ Compute hierarchy
    10:51:33 │ │ │ │ └ 1.995s
    10:51:33 │ │ │ ├ Dumping stubs
    10:51:37 │ │ │ │ └ 4.542s
    10:51:37 │ │ │ └ 14.720s
    10:51:37 │ │ ├ Found 3404 items.
    10:51:37 │ │ ├ Found 3402 facts.
    10:51:37 │ │ ├ The core is 96 of them.
    10:51:37 │ │ └ 14.770s
    10:51:37 │ ├ Compute CNF
    10:51:43 │ │ └ 6.089s
    jreduce: Maybe.fromJust: Nothing
    CallStack (from HasCallStack):
    error, called at libraries/base/Data/Maybe.hs:148:21 in baseata.Maybe
    fromJust, called at src/JReduce/Logic.hs:519:40 in jreduce-0.1.0-Abs4ufFiDadAKpDliDdD1j:JReduce.Logic
    CallStack (from -prof):
    JReduce.Logic.describeLogicProblem..showGraphVar (src/JReduce/Logic.hs518,5)-(519,67))
    JReduce.Logic.describeLogicProblem.\ (src/JReduce/Logic.hs481,91)-(556,5))
    JReduce.Logic.describeLogicProblem (src/JReduce/Logic.hs481,1)-(556,5))
    JReduce.Logic.CAF:lvl35_r1uUy ()
@kalhauge
Copy link
Collaborator

It might be a bug in the reverse lookup of the variable names. I will look at it eventually, but for now a work around as you mention it yourself is to not enable the --dump flag.

@kalhauge kalhauge added the bug Something isn't working label Sep 30, 2021
@kalhauge kalhauge self-assigned this Sep 30, 2021
@kalhauge
Copy link
Collaborator

The error disappears when the --dump option is removed, but the tool runs too many iterations (450 iterations, ~45minutes, after which the run was manually terminated)

Why is 450, too many iterations? 450 might be a reasonable number of iterations depending on the predicate.

@akshayutture
Copy link
Author

Right. I don't know why I thought 450 was too many iterations.

But I tried running again, and it did not terminate in 5 hours (even though a timeout of 1800 was set) on 2 of the benchmarks I tried. Should I create a separate bug report for that?

@kalhauge
Copy link
Collaborator

kalhauge commented Oct 1, 2021

Yes, that sounds like a separate issue. Please do that :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants