ml4ai / automates

AutoMATES: Automated Model Assembly from Text, Equations, and Software
https://ml4ai.github.io/automates
Other
25 stars 9 forks source link

[PA]: Allow custom gcc-10 path and more if-statement unit tests for gcc plugin #275

Closed rsulli55 closed 2 years ago

rsulli55 commented 2 years ago

This PR is consists of two things:

1) Updating run_gcc_to_grfn.py, the gcc plugin Makefile, and test_gcc_plugin_c.py with the goals of

if_else_statement unit test

This unit test also has problems with the created GrFN. The issues again appears to be the I blocks, and as above, the CAST looks fine. See Issue #276 if_else_statement--CAST.pdf if_else_statement--GrFN.pdf

if_elif_statement unit test

This unit test has problems with the CAST (which also causes the GrFN to be incorrect and execution results to be wrong). In the CAST you can see the else if statements are not attached to the else block like they should. I checked the gcc_ast.json, and that correctly attaches the else if off the else branch. It sounds like this issue is fixed on a branch Tito is working on if_elif_statement--CAST.pdf if_elif_statement--GrFN.pdf

codecov[bot] commented 2 years ago

Codecov Report

Merging #275 (77f6c22) into master (80c8a7c) will decrease coverage by 0.90%. The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #275      +/-   ##
==========================================
- Coverage   67.20%   66.29%   -0.91%     
==========================================
  Files          94       94              
  Lines       17821    17821              
==========================================
- Hits        11976    11814     -162     
- Misses       5845     6007     +162     
Impacted Files Coverage Δ
...analysis/CAST2GrFN/visitors/cast_to_air_visitor.py 42.75% <0.00%> (-19.26%) :arrow_down:
...mates/program_analysis/GCC2GrFN/gcc_ast_to_cast.py 56.04% <0.00%> (-7.46%) :arrow_down:
...gram_analysis/CAST2GrFN/model/cast_to_air_model.py 77.68% <0.00%> (-4.81%) :arrow_down:
...s/CAST2GrFN/visitors/cast_function_call_visitor.py 85.71% <0.00%> (-0.90%) :arrow_down:
automates/model_analysis/graph_manipulation.py 70.19% <0.00%> (-0.56%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 80c8a7c...77f6c22. Read the comment docs.