Performance Regression due preciseMath being on by default

Description

https://github.com/lucee/Lucee/commit/c623dbb4ee78de7acb206c429115baea139fe99d

it’s about four times slower calculating primes on my Windows i7 laptop 27s vs 114s

this language is quite optimistic!

image-20241118-191324.png

https://github.com/lucee/lucee-testlab/blob/main/custom/benchmark/tests/primes.cfm

Environment

None

Attachments

9
  • 19 Nov 2024, 11:53 am
  • 19 Nov 2024, 11:53 am
  • 19 Nov 2024, 11:53 am
  • 19 Nov 2024, 11:53 am
  • 19 Nov 2024, 11:53 am
  • 19 Nov 2024, 11:53 am
  • 19 Nov 2024, 11:53 am
  • 19 Nov 2024, 11:53 am
  • 18 Nov 2024, 07:14 pm

Activity

Show:

Pothys - MitrahSoft 19 December 2024 at 15:01

, I have investigated this ticket with Lucee version 6.2.0.230-SNAPSHOT. When I compared the performance time in the test lab with the default PreciseMath set to false, the performance was slightly increased. Now, in the latest version of Lucee, the performance has improved, therefore, I am going to close this ticket.

Zac Spitzer 4 December 2024 at 13:03
Edited

Zac Spitzer 19 November 2024 at 13:30

Looking at the max times with loops, they are higher when precise math is enabled, I’m guessing there’s more GC going on

Zac Spitzer 19 November 2024 at 11:53
Edited

it’s on by default in 6.0, 6.1 and 6.2

here’s the spreadsheet-cfml benchmarks

image-20241119-105640.png

and with LUCEE_PRECISE_MATH=false

image-20241119-105613.png

here are the benchmarks

LUCEE_PRECISE_MATH=false

image-20241119-114123.png

https://github.com/lucee/lucee-testlab/actions/runs/11911949700/attempts/1#summary-33195596635

and with LUCEE_PRECISE_MATH=true (unset, i.e default)

image-20241119-114214.png

https://github.com/lucee/lucee-testlab/actions/runs/11911586638/attempts/1#summary-33194409458

loops and primes for example are really improved

image-20241119-114745.png

and with LUCEE_PRECISE_MATH=false

image-20241119-114814.png

interestingly, json seems to regress performance wise? https://luceeserver.atlassian.net/browse/LDEV-5162

image-20241119-115134.png

and with LUCEE_PRECISE_MATH=false

image-20241119-115200.png
Fixed

Details

Assignee

Reporter

Priority

Fix versions

New Issue warning screen

Before you create a new Issue, please post to the mailing list first https://dev.lucee.org

Once the issue has been verified, one of the Lucee team will ask you to file an issue

Sprint

Created 18 November 2024 at 19:11
Updated 19 December 2024 at 15:02
Resolved 19 December 2024 at 15:02

Flag notifications