Skip to content

Conversation

@Lunderberg
Copy link
Contributor

A check for unsigned integer overflow would throw an error if it encountered 0U - 0U.

#10484, which introduced the check, and #9727, which introduced this edge case, were in CI at the same time, and each was tested against a merge candidate that did not include the other. The unittest failure only occurred when both PRs were merged.

@Lunderberg Lunderberg changed the title [Bugfix] Allow constant folding of 0U - 0U [skip ci][Bugfix] Allow constant folding of 0U - 0U Mar 8, 2022
A check for unsigned integer overflow would throw an error if it
encountered 0U - 0U.

apache#10484, which introduced the check,
and apache#9727, which introduced this
edge case, were in CI at the same time, and each was tested against a
merge candidate that did not include the other.  The unittest failure
only occurred when both PRs were merged.
@Lunderberg Lunderberg force-pushed the uint_overflow_bugfix branch from d00ea62 to 6273032 Compare March 8, 2022 23:08
@Lunderberg
Copy link
Contributor Author

I liked @driazati 's recommentation to update the name with [skip ci] in order to unbreak main sooner.

@masahi masahi merged commit a8a2574 into apache:main Mar 9, 2022
@AndrewZhaoLuo
Copy link
Contributor

Can we do something like

    ICHECK(!(pa && pa->dtype.is_uint() && pb && pb->dtype.is_uint() && pa->value >= pb->value))
        << "Checked failed. Minuend's value " << pa->value << "U while Subtrahend's value is "
        << pb->value << "U which will cause a negative uint";

Instead?

@Lunderberg Lunderberg deleted the uint_overflow_bugfix branch March 9, 2022 14:54
ziqiangxu8457 pushed a commit to ziqiangxu8457/tvm that referenced this pull request Mar 9, 2022
A check for unsigned integer overflow would throw an error if it
encountered 0U - 0U.

apache#10484, which introduced the check,
and apache#9727, which introduced this
edge case, were in CI at the same time, and each was tested against a
merge candidate that did not include the other.  The unittest failure
only occurred when both PRs were merged.
pfk-beta pushed a commit to pfk-beta/tvm that referenced this pull request Apr 11, 2022
A check for unsigned integer overflow would throw an error if it
encountered 0U - 0U.

apache#10484, which introduced the check,
and apache#9727, which introduced this
edge case, were in CI at the same time, and each was tested against a
merge candidate that did not include the other.  The unittest failure
only occurred when both PRs were merged.
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.

4 participants