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

Bump ch.randelshofer:fastdoubleparser from 1.0.1 to 2.0.0 #214

Merged

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Oct 25, 2024

Bumps ch.randelshofer:fastdoubleparser from 1.0.1 to 2.0.0.

Release notes

Sourced from ch.randelshofer:fastdoubleparser's releases.

Release 2.0.0 with ConfigurableDoubleParser

The Release 2.0.0 adds a ConfigurableDoubleParser to the library.

The ConfigurableDoubleParser supports parsing of double numbers in localed formats, similar to java.text.DecimalFormat.

Examples:

        var symbols = NumberFormatSymbols.fromDecimalFormatSymbols(new DecimalFormatSymbols(Locale.GERMAN));
        boolean ignoreCase = true;
        var confdParser = new ConfigurableDoubleParser(symbols, ignoreCase);
        double confD1 = confdParser.parseDouble("123.456,89e5");
        double confD2 = confdParser.parseDouble("-0.15425,89E-5");
        System.out.println("Double value in German Locale: " + confD1);
        System.out.println("Another double value in German Locale: " + confD2);
    symbols = NumberFormatSymbols.fromDecimalFormatSymbols(new DecimalFormatSymbols(Locale.forLanguageTag("zh-CN")));
    symbols = symbols
            .withDigits(List.of('〇', '一', '二', '三', '四', '五', '六', '七', '八', '九'))
            .withExponentSeparator((Set.of("*一〇^")));
confdParser = new ConfigurableDoubleParser(symbols, ignoreCase);
double confZh = confdParser.parseDouble("四一.五七五三七一六六二一四五九八*一〇^");
System.out.println("Double value in Chinese Locale: " + confZh);

Workaround for Zing JVM

This release contains a workaround for the Zing JVM.

OpenJDK Runtime Environment Zing24.09.0.0+5 (build 21.0.4+4-LTS)
Zing 64-Bit Tiered VM Zing24.09.0.0+5 (build 21.0.4-zing_24.09.0.0-b5-release-linux-X86_64, mixed mode)

Instead of calling {@​link Math#unsignedMultiplyHigh(long, long)}
we use our own implementation.

This version will perform slightly slower than the v1.0.1 release. The JIT should generate a single MUL instruction for Math#unsignedMultiplyHigh(long, long). This workaround consists of 6 lines of Java code that simulates this instruction.

Commits
  • d62dcfa Use version number 2.0.0. Update README.md.
  • bd0723b Replace Java 22 by Java 23 in README.md.
  • 4f8a183 Mark classes with final to make life easier for the JIT.
  • b2fc12e Return a magic bit pattern instead of throwing an exception.
  • 5e6ce73 Add javadoc for parameters.
  • 8dfe653 The constructor of NumberFormatSymbols creates defensive copies of all collec...
  • 583e836 Remove unused filterInputString() methods.
  • 74a507f Improve code example.
  • 56e89d0 Add javadoc.
  • 114324c Build without preview features.
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot bot added dependencies Pull requests that update a dependency file java Pull requests that update Java code labels Oct 25, 2024
@devinrsmith devinrsmith self-assigned this Oct 28, 2024
Copy link
Member

@devinrsmith devinrsmith left a comment

Choose a reason for hiding this comment

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

It looks like this release is mainly in support of a new feature that allows parsing of different locales; see wrandelshofer/FastDoubleParser#82.

While we don't directly expose this as an option, end-users would be able to easily wrap their own CustomDoubleParser with fastdoubleparser and set io.deephaven.csv.CsvSpecs#customDoubleParser.

In the future, we may want to consider either explicitly enabling Local parsing options, or make CustomDoubleParser configurable per-column.

@devinrsmith
Copy link
Member

@dependabot rebase

Bumps [ch.randelshofer:fastdoubleparser](https://github.com/wrandelshofer/FastDoubleParser) from 1.0.1 to 2.0.0.
- [Release notes](https://github.com/wrandelshofer/FastDoubleParser/releases)
- [Commits](wrandelshofer/FastDoubleParser@v1.0.1...v2.0.0)

---
updated-dependencies:
- dependency-name: ch.randelshofer:fastdoubleparser
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot force-pushed the dependabot/gradle/ch.randelshofer-fastdoubleparser-2.0.0 branch from ae549a7 to 2bbacd7 Compare October 28, 2024 19:55
@devinrsmith
Copy link
Member

JMH testing of DoubleColumnBenchmark.deephaven shows no discernible difference; ~43m ops/s on my machine.

@devinrsmith devinrsmith requested a review from kosak October 28, 2024 19:58
@devinrsmith devinrsmith merged commit c3fbcf2 into main Oct 28, 2024
3 checks passed
@devinrsmith devinrsmith deleted the dependabot/gradle/ch.randelshofer-fastdoubleparser-2.0.0 branch October 28, 2024 21:21
@github-actions github-actions bot locked and limited conversation to collaborators Oct 28, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
dependencies Pull requests that update a dependency file java Pull requests that update Java code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants