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

Dont crash when seeing invalid tree while tracing #3537

Merged
merged 1 commit into from
Jan 31, 2019

Conversation

cathyzhyi
Copy link
Contributor

When seeing NULLChk without NULLChkReference while printing trees
to tracing log, we should try to continue printing the complete
trees which makes debugging easier.

Signed-off-by: Yi Zhang yizhang@ca.ibm.com

output.append(" on %s%dn", globalIndexPrefix.getStr(), node->getNullCheckReference()->getGlobalIndex());
if (node->getNullCheckReference())
output.append(" on %s%dn", globalIndexPrefix.getStr(), node->getNullCheckReference()->getGlobalIndex());
else output.append(" on null NullCheckReference ----- INVALID tree!!\n");
Copy link
Contributor

Choose a reason for hiding this comment

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

From a consistency POV, this message ends with a newline but all others in a similar context don't. Arguably, trying to print an invalid tree is breaking the mold, but can you confirm that the newline is what you want here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for pointing that out. I removed the newline.

When seeing NULLChk without NULLChkReference while printing trees
to tracing log, we should try to continue printing the complete
trees which makes debugging easier.

Signed-off-by: Yi Zhang <yizhang@ca.ibm.com>
@0xdaryl
Copy link
Contributor

0xdaryl commented Jan 31, 2019

@genie-omr build all

@0xdaryl 0xdaryl self-assigned this Jan 31, 2019
@0xdaryl 0xdaryl merged commit 30799a5 into eclipse-omr:master Jan 31, 2019
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