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

Generalization tool #805

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Generalization tool #805

wants to merge 1 commit into from

Conversation

manasij7479
Copy link
Collaborator

No description provided.

@regehr
Copy link
Collaborator

regehr commented Dec 10, 2020

ok good, I like that this is removing code from Solver.cpp

#include "llvm/Support/KnownBits.h"

#include "souper/Infer/Preconditions.h"

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does this blank line among souper includes serve a purpose?

Solver *S, ParsedReplacement Input) {

if (DebugLevel > 1) {
llvm::errs() << "Attempting to generalize by removing leaf.\n";
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

indentation error


std::set<Inst *> Visited;
while (!Stack.empty()) {
auto Current = Stack.back();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

indentation error.

if you're having trouble with basic code formatting, why not get into the habit of running clang-format on new files before contributing them?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea, I'll do them cmake tweaking required for running ninja format or make format.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for now, please only do this on new files that are being added to the repo. doing this for existing files would be fun, but it would make it effectively impossible to ever merge any existing branch. we can only do this at a time where we're certain that no non-trivial branches exist. at least one exists right now, and probably more.

@@ -0,0 +1,22 @@
; REQUIRES: solver, synthesis
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since this test is just looking for a bunch of LGTMs out of a two-step process, it's not really possible to see what behavior it's actually testing. please modify it to only run your new tool, and then check that its output is correct without invoking a second tool, so we can look at the test and understand what's going on. also do this to the other test.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, sounds good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants