ibm / novia Goto Github PK
View Code? Open in Web Editor NEWNOVIA ontology toolset for discovery of unconventional inline accelerators
NOVIA ontology toolset for discovery of unconventional inline accelerators
Hi there, I've successfully followed the Docker Install and Docker Run steps as outlined in the README. However, I run into issues with the automated analysis scripts when running the examples. It seems that the formatting of source.log
creates errors when being parsed by preanalysis.py
.
For each example, except for incremental
, I see the following error during the Pre-merge Report
:
Traceback (most recent call last):
File "/opt/NOVIA/fusion/analysis/scripts/preanalysis.py", line 59, in <module>
main(sys.argv[1:])
File "/opt/NOVIA/fusion/analysis/scripts/preanalysis.py", line 30, in main
funcs = re.search("\[.*\]",line).group(0)[1:-2].split(';')
AttributeError: 'NoneType' object has no attribute 'group'
I see that the first line,Original
, from source.log
is being searched for brackets. re.search("\[.*\]","Original")
returns NoneType
, which prompts the error AttributeError: 'NoneType' object has no attribute 'group'
. Within preanalysis.py
at line 30, would skipping lines that do not have these brackets permanently solve this issue without breaking the pipeline? Modifying lines 27-32 of preanalysis.py
as such appears to work for me:
for num, line in enumerate(fsource, 1):
if str(fstats['BB'][i]) in line:
start = num
if re.search("\[.*\]", line) is not None:
funcs = re.search("\[.*\]",line).group(0)[1:-2].split(';')
if(funcs[0] != ''):
Thank you for the help! NOVIA is quite a neat tool ๐
Edit: I've opened a pull request with this fix.
Hello there! Would it be possible to integrate the generation of .dot files alongside the .pngs generated by NOVIA?
It would be useful on our end since some of our software analysis utilities ingest .dot files.
Thanks for your nice work!
Will you further open-source the hardware support and compiler support as the readme refers?
Hello again! I've been attempting to run Novia on my own bitcode and have run into problems with clang and LLVM.
As a preface, I have built two Novia Docker images:
scripts/compile_llvm_minimal.sh
scripts/compile_llvm.sh
I have my own code (a sparse-matrix multiply called spmm
) that is built using CMake's -flto
flag to emit LLVM IR bitcode (see this Stack Overflow post for how I accomplish this). I realize that I could copy one of the examples in fusion/examples
and create a Makefile, but it would be nice to have my CMake build process work since my code can become quite complex.
scripts/compile_llvm_minimal.sh
I followed the README and am able to successfully emit bitcode in the examples (fusion/examples/*
). However, when attempting to use CMake on my own code (spmm
), I see the following error:
root@etc-gpu-09:/opt/spmm/build# make
Scanning dependencies of target spmm
[ 25%] Building CXX object src/CMakeFiles/spmm.dir/main.cc.o
[ 50%] Building CXX object src/CMakeFiles/spmm.dir/dmm.cc.o
[ 75%] Building CXX object src/CMakeFiles/spmm.dir/spmm.cc.o
[100%] Linking CXX executable spmm
/usr/bin/ld: /opt/NOVIA/llvm-project/build/bin/../lib/LLVMgold.so: error loading plugin: /opt/NOVIA/llvm-project/build/bin/../lib/LLVMgold.so: cannot open shared object file: No such file or directory
clang-13: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [src/CMakeFiles/spmm.dir/build.make:114: src/spmm] Error 1
make[1]: *** [CMakeFiles/Makefile2:94: src/CMakeFiles/spmm.dir/all] Error 2
make: *** [Makefile:95: all] Error 2
Below is a screenshot of what the setup looks like from within the container:
I believe this is because scripts/compile_llvm_minimal.sh
does not build lld
, LLVM's linker. As such, I attempted to build the second Docker image using scripts/compile_llvm.sh
for a full build.
scripts/compile_llvm.sh
For the second image, the only modification is to scripts/install.sh
, which now looks like this:
...
$DIR/scripts/compile_graphviz.sh
$DIR/scripts/compile_llvm.sh
...
After building, I run the container and attempt to use clang
, but there does not appear to be one:
> source NOVIA/env.sh
> clang --version
bash: clang: command not found
Within my CMakeErrors.log, I see many issues indicating something going wrong with the build process. A sample of this is as follows:
Run Build Command(s):/usr/bin/ninja cmTC_d4fe0 && [1/2] Building C object CMakeFiles/cmTC_d4fe0.dir/CheckIncludeFile.c.o
FAILED: CMakeFiles/cmTC_d4fe0.dir/CheckIncludeFile.c.o
/usr/bin/cc -o CMakeFiles/cmTC_d4fe0.dir/CheckIncludeFile.c.o -c CheckIncludeFile.c
CheckIncludeFile.c:1:10: fatal error: malloc/malloc.h: No such file or directory
1 | #include <malloc/malloc.h>
| ^~~~~~~~~~~~~~~~~
compilation terminated.
ninja: build stopped: subcommand failed.
Is there some -D___
flag in scripts/install_llvm.sh
that is missing?
Is there a specific reason why llvm-13
was chosen? Will there eventually be support for other versions of llvm
in the future?
Thank you for the help!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.