-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
[TARGET] each option of target str should only contain one '=' #5988
Conversation
874a657
to
c0aeacb
Compare
Ah I see, I am a bit surprised the typo is not found before. BTW, please rebase to master, and change “-target” to “-mtriple”. Thanks! |
c0aeacb
to
5fef34d
Compare
done! old code works ok before "[Target] Migrate data structure of TargetNode (#5960)", the commit add a requirement in src/target/target_id.cc. FindUniqueSubstr require options string has only one '=', we didn't force the limit before that commit. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
@windclarion Looks like a flaky test. Could you file an empty commit using |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you also add unit tests generating code for those target, which will also re-trigger the CI?
5fef34d
to
2362920
Compare
@ZihengJiang I try to add test, but if I feed the option with a string which contains two '=', target_id.cc FindUniqueSubstr CHECK will abort, so I don't know how can I test the abort operation, it's not a exception which I can catch, it's just abort. Can you give me some advice or tell me similar test file which can test the CHECK? |
@junrushao1994 What I have said maybe not very clear, I mean I can't catch a exception in python code, because C++ CHECK just abort, the abort function didn't throw a exception. |
2362920
to
5e505d9
Compare
@junrushao1994 I add a small test which just test target whether can be created, and I just make sure the target shouldn't be None. |
today's test is flaky, I always failed at the unexpected position, and I don't know how can I cause the fail |
Yeah seems like another flaky test...Could you re-trigger? Thanks! |
I see. There is a flaky test in the recent week: #6009. Don't worry, let's wait until it is fixed. |
@windclarion Could you try to build a small program like |
The flaky test is resolved in #6014 :-) |
5e505d9
to
87ca226
Compare
@ZihengJiang many other tests has tested tvm.build, ex. tests\python\integration\test_reduce.py test_reduce_prims Line64 has checked metal, vulkan, cuda, opencl, rocm |
src/target/target_id.cc ParseAttrsFromRawString L222: if ((pos = FindUniqueSubstr(s, "=")) != -1) require option contains only one '=' Signed-off-by: windclarion <windclarion@gmail.com>
87ca226
to
2bba6b7
Compare
…e#5988) src/target/target_id.cc ParseAttrsFromRawString L222: if ((pos = FindUniqueSubstr(s, "=")) != -1) require option contains only one '=' Signed-off-by: windclarion <windclarion@gmail.com>
…e#5988) src/target/target_id.cc ParseAttrsFromRawString L222: if ((pos = FindUniqueSubstr(s, "=")) != -1) require option contains only one '=' Signed-off-by: windclarion <windclarion@gmail.com>
src/target/target_id.cc ParseAttrsFromRawString L222:
if ((pos = FindUniqueSubstr(s, "=")) != -1)
require option contains only one '='
The CHECK code in FindUniqueSubstr will cause build fail.
Signed-off-by: windclarion windclarion@gmail.com