You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@giraph.apache.org by "Arun Suresh (Commented) (JIRA)" <ji...@apache.org> on 2011/11/15 09:23:52 UTC
[jira] [Commented] (GIRAPH-87) Simplify boolean expression in
BspService::checkpointFrequencyMet
[ https://issues.apache.org/jira/browse/GIRAPH-87?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13150298#comment-13150298 ]
Arun Suresh commented on GIRAPH-87:
-----------------------------------
you would still need the first case..
for eg. if
superstep = 4
firstCheckpoint = 6
checkpointFrequency = 2
would return true if we only have the else if
> Simplify boolean expression in BspService::checkpointFrequencyMet
> -----------------------------------------------------------------
>
> Key: GIRAPH-87
> URL: https://issues.apache.org/jira/browse/GIRAPH-87
> Project: Giraph
> Issue Type: Improvement
> Reporter: Jakob Homan
> Labels: newbie
>
> {noformat} if (superstep < firstCheckpoint) {
> return false;
> } else if (((superstep - firstCheckpoint) % checkpointFrequency) == 0) {
> return true;
> } else {
> return false;
> }{noformat}
> can be simplified to just return the result of the else if evaluation.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira