-
Notifications
You must be signed in to change notification settings - Fork 131
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
Write seperate pass for function dot file generation. Don't overwrite dot files. #87
Comments
Thanks ChenYuan! I'll add In the longer run, we need to update our scripts so we don't override dot-files. |
Just reopening, so we don't loose track. |
Do not override dot files is easier said than done. When compiling a single compile unit, I think the compiler do not know which binary this unit will be built into. So, the compiler cannot just name the dot file as format Even if we keep same named files using like I think the easist way to solve this issue is to require user to just compile target binary, like |
One way to address this, is to extract the function dot file generation part of the pass into a separate pass. Then one could use Something like
|
@Liblor, this is a great suggestion! @zjuchenyuan You are welcome to submit a pull request if this works for you. |
Different binaries may have the functions with same name, the most common one is the
main
function.When generating dot files, only function name is kept in naming the dot file for this function. Therefore, for preprocessing building process, only the last compiled binary's
main
function's dot file will be retained.For example, following the instruction from README, to build xmllint, you give
make all
, and I get thiscfg.main.dot
:Since
example/gjobread
is the last built binary, its main function dot is kept, not the target binaryxmllint
.I think this is a problem leading to wrong CFG distance analaysis, and I suggest:
make xmllint
to avoid building other binaries.1
.2
?)The text was updated successfully, but these errors were encountered: