[
https://issues.apache.org/jira/browse/FLINK-3928?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15289531#comment-15289531
]
Greg Hogan commented on FLINK-3928:
-----------------------------------
Nice find! How did you find this? The {{RMatGraph}} generator currently tops
out around scale 30 and I'll need to implement the PRNG sources with
{{SplittableIterator}} to fix that (s30e8 is ~200B triangles from ~2T triplets).
> Potential overflow due to 32-bit int arithmetic
> -----------------------------------------------
>
> Key: FLINK-3928
> URL: https://issues.apache.org/jira/browse/FLINK-3928
> Project: Flink
> Issue Type: Bug
> Reporter: Ted Yu
> Assignee: Greg Hogan
> Priority: Minor
>
> The following pattern occurs in both LocalClusteringCoefficient.java and
> TriangleListing.java :
> {code}
> int scale = parameters.getInt("scale", DEFAULT_SCALE);
> ...
> long vertexCount = 1 << scale;
> {code}
> "1 << scale" may overflow with type "int" due to the use of 32-bit arithmetic
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)