Skip to content

Instantly share code, notes, and snippets.

@casperisfine
Last active November 4, 2024 09:21
Show Gist options
  • Save casperisfine/296b1772a580a56d80748aafafed2cd5 to your computer and use it in GitHub Desktop.
Save casperisfine/296b1772a580a56d80748aafafed2cd5 to your computer and use it in GitHub Desktop.
== Parsing activitypub.json (58160 bytes)
ruby 3.3.5 (2024-09-03 revision ef084cc8f4) +YJIT [arm64-darwin23]
Warming up --------------------------------------
json 2.8.0.alpha1 891.000 i/100ms
oj 794.000 i/100ms
Calculating -------------------------------------
json 2.8.0.alpha1 8.879k (± 7.4%) i/s (112.62 μs/i) - 44.550k in 5.058132s
oj 7.916k (± 1.7%) i/s (126.32 μs/i) - 39.700k in 5.016420s
Comparison:
json 2.7.2: 6286.5 i/s
json 2.8.0.alpha1: 8879.3 i/s - 1.41x faster
oj: 7916.4 i/s - 1.26x faster
== Parsing twitter.json (567916 bytes)
ruby 3.3.5 (2024-09-03 revision ef084cc8f4) +YJIT [arm64-darwin23]
Warming up --------------------------------------
json 2.8.0.alpha1 77.000 i/100ms
oj 63.000 i/100ms
Calculating -------------------------------------
json 2.8.0.alpha1 800.596 (± 7.5%) i/s (1.25 ms/i) - 4.004k in 5.041135s
oj 631.444 (± 2.1%) i/s (1.58 ms/i) - 3.213k in 5.090820s
Comparison:
json 2.7.2: 514.4 i/s
json 2.8.0.alpha1: 800.6 i/s - 1.56x faster
oj: 631.4 i/s - 1.23x faster
== Parsing citm_catalog.json (1727030 bytes)
ruby 3.3.5 (2024-09-03 revision ef084cc8f4) +YJIT [arm64-darwin23]
Warming up --------------------------------------
json 2.8.0.alpha1 42.000 i/100ms
oj 33.000 i/100ms
Calculating -------------------------------------
json 2.8.0.alpha1 412.220 (± 8.0%) i/s (2.43 ms/i) - 2.058k in 5.040826s
oj 334.175 (± 2.1%) i/s (2.99 ms/i) - 1.683k in 5.038873s
Comparison:
json 2.7.2: 295.1 i/s
json 2.8.0.alpha1: 412.2 i/s - 1.40x faster
oj: 334.2 i/s - 1.13x faster
== Parsing activitypub.json (58160 bytes)
ruby 3.4.0preview2 (2024-10-07 master 32c733f57b) +YJIT +PRISM [arm64-darwin23]
Warming up --------------------------------------
json 2.8.0.alpha1 892.000 i/100ms
oj 781.000 i/100ms
Calculating -------------------------------------
json 2.8.0.alpha1 8.794k (± 6.9%) i/s (113.72 μs/i) - 44.600k in 5.112329s
oj 7.664k (± 4.6%) i/s (130.48 μs/i) - 38.269k in 5.005196s
Comparison:
json 2.7.2: 6185.6 i/s
json 2.8.0.alpha1: 8793.9 i/s - 1.42x faster
oj: 7664.0 i/s - 1.24x faster
== Parsing twitter.json (567916 bytes)
ruby 3.4.0preview2 (2024-10-07 master 32c733f57b) +YJIT +PRISM [arm64-darwin23]
Warming up --------------------------------------
json 2.8.0.alpha1 81.000 i/100ms
oj 62.000 i/100ms
Calculating -------------------------------------
json 2.8.0.alpha1 779.907 (± 9.9%) i/s (1.28 ms/i) - 3.888k in 5.072243s
oj 598.206 (± 7.4%) i/s (1.67 ms/i) - 2.976k in 5.018013s
Comparison:
json 2.7.2: 496.3 i/s
json 2.8.0.alpha1: 779.9 i/s - 1.57x faster
oj: 598.2 i/s - 1.21x faster
== Parsing citm_catalog.json (1727030 bytes)
ruby 3.4.0preview2 (2024-10-07 master 32c733f57b) +YJIT +PRISM [arm64-darwin23]
Warming up --------------------------------------
json 2.8.0.alpha1 40.000 i/100ms
oj 33.000 i/100ms
Calculating -------------------------------------
json 2.8.0.alpha1 400.882 (±10.2%) i/s (2.49 ms/i) - 2.000k in 5.081016s
oj 332.303 (± 7.2%) i/s (3.01 ms/i) - 1.650k in 5.002145s
Comparison:
json 2.7.2: 278.8 i/s
json 2.8.0.alpha1: 400.9 i/s - 1.44x faster
oj: 332.3 i/s - 1.19x faster
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment