-
Notifications
You must be signed in to change notification settings - Fork 11
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
Implement full pipeline #16
Comments
|
Prefect ! |
Hi @shrin18, We have the point 2. right? |
Hey @Jacarte
It would be much better if there is one way to directly support |
Hi, @Jacarte As per my understanding, last week we did a jump from 1. to 3. . Currently compilation from .wast programs in benchmark programs is directly possible so that we can eliminate the llvm part as discussed. Also, souper candidates have two formats, textual human readable format in S-language of WASM and pure binary format.
This code seems to accept a wasm file on input and so I used wabt to convert wast to wasm. Does that seem logical ? @Jacarte @jianguda |
Hey @shrin18 Great!
if we need assembly filetype:
or we need binary filetype:
|
Current solution for This is related discussion. |
Another feasible solution is to reuse some implementations inside wasmer, I made one issue there. |
Right now, step2 My current plan is to study wasmer to directly support |
What about improving wasm-opt in binaryen? |
For wasm-opt, I am trying to locate |
We are trying to get valid candidates in souper in the .opt extension. On the input we are parsing .wasm or .wat files and as per the pipeline we should get required valid candidates for each of the .wasm or .wat program files. However the program throws some unexpected error regarding the syntax of the .wasm programs and it is different for each of the program per se. Further, it is good that the program succeeds in getting binary output from the llvm extensions and so we can narrow down the problem on the working of wasm-opt function. |
For example, we have one file named "fib.opt":
We run
Actually we need valid width info as type It is okay to fix this issue by improving |
WAST -> WASM -> Souper -> LLVM -> WASM |
As discussed with @shrin18, for the souper2llvm step, we have to improve existing solutions (Python or C++) in souper by ourselves. I am doing the C++ plan at |
excellent. hopefully, we can contribute back upstream with a PR.
|
Progress Note: We have tried the C++ plan and found currently it seems only support RHS, which is consistent with this statement. @shrin18 and I will discuss and decide our next step. |
OK, good progress!
|
Hey @Jacarte
|
The problem is when you try to generate the ll representation from C or another high-level :(
… On 7 Nov 2019, at 19:58, Jian GU ***@***.***> wrote:
Hey @Jacarte <https://github.com/Jacarte>
This is one sample <https://github.com/KTH/slumps/tree/master/utils/pipeline/_infer> which shows the correctness of most steps in our pipeline
(.ll->.bc->.cand.opt->.lhs.opt->.rhs.opt->.new.ll->.new.bc)
infer.ll was converted from infer.opt <https://github.com/google/souper/blob/master/test/Tool/infer.opt> by using the souper2llvm.py <https://github.com/google/souper/blob/master/utils/souper2llvm.in> script
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#16>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AEBD5WZJHBN62V3GCPMR3QTQSRQMHANCNFSM4IYUJBTQ>.
|
We patch the issue where the souperify pass was broken (here the PR) in binaryen. Now we can go directly from WASM to souper without the use of LLVM. This is better for our purposes because we can avoid initial optimization from LLVM. Preliminary results show even more candidates going directly from WASM, which means more variations for our final goal. |
We are able to reproduce experiments shown in the Souper paper, once we sync latest commits from the upstream repo to KTH/souper. Check this issue for more info. |
that's a major milestone. well done! |
We are closing it because we have the first implementation of this pipeline. We decided to improve the feed of souper going directly from WASM to Souper IR. The main idea is to extend swam due to, first, it's a well-tested parser, second, we have no feedback from the binaryen PR with the Souper integration fix. |
Implement full pipeline tool
We have the inner pieces and the vulnerabilities to test it. We can start to create the full pipeline
The text was updated successfully, but these errors were encountered: