Skip to content

Conversation

@kun-zh
Copy link
Contributor

@kun-zh kun-zh commented Apr 8, 2018

Generate Lower Bound Conditions for issue #1014

kun-zh and others added 30 commits December 25, 2017 23:21
update the fork branch
@tqchen
Copy link
Member

tqchen commented Apr 10, 2018

there is a regression test failure, @kun-zh can you look into that? http://mode-gpu.cs.washington.edu:8080/blue/organizations/jenkins/dmlc%2Ftvm/detail/PR-1091/3/pipeline

Expr value = ComputeExpr<Sub>(value_map.at(iv), iv->dom->min);
Expr vmin = EvalSet(value, iset_dmap).min();
Expr vmax = EvalSet(value, iset_dmap).max();
if (vmin.type() != value.type() || !can_prove(vmin > (iv->dom->min - 1))) {
Copy link
Member

Choose a reason for hiding this comment

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

vmin >= iv->dom->min

Expr vmin = EvalSet(value, iset_dmap).min();
Expr vmax = EvalSet(value, iset_dmap).max();
if (vmin.type() != value.type() || !can_prove(vmin > (iv->dom->min - 1))) {
preds.emplace_back(value > (iv->dom->min - 1));
Copy link
Member

Choose a reason for hiding this comment

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

value >= iv->dom->min

@kun-zh
Copy link
Contributor Author

kun-zh commented Apr 11, 2018

refined and fixed regression failure

CHECK(iv->dom.defined());
if (!skip_ivar_domain && !iv->dom.same_as(dom)) {
Expr value = ComputeExpr<Sub>(value_map.at(iv), iv->dom->min);
Expr vmin = EvalSet(value, iset_dmap).min();
Copy link
Member

Choose a reason for hiding this comment

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

Do EvalSet once, instead of multiple times

Copy link
Member

Choose a reason for hiding this comment

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

specifically, cache the result of EvalSet and then get min and max

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants