Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(4680)

Issue 559820044: rational: optimize comparison (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
4 years ago by hanwenn
Modified:
4 years ago
Reviewers:
CC:
lilypond-devel_gnu.org
Visibility:
Public.

Description

rational: optimize comparison calculating sign(left-right) is correct, but requires an unnecessary GCD calculation to normalize the result. Rational::compare takes about 1% of cumulative time in the carver MDSM profile

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+29 lines, -2 lines) Patch
M flower/GNUmakefile View 1 chunk +1 line, -1 line 0 comments Download
M flower/rational.cc View 1 chunk +13 lines, -1 line 0 comments Download
M flower/test-rational.cc View 1 chunk +15 lines, -0 lines 0 comments Download

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b