Skip to content

Floating-point precision issues #12356

Description

@littlelittlewhite09

Backend

VL (Velox)

Bug description

SQL:select cast (2.8 / cast(0.0130597014925373134 as decimal(38,19)) as double);
Gluten(spark.sql.optimizer.excludedRules=org.apache.spark.sql.catalyst.optimizer.ConstantFolding): 214.39999999999998
vanilla Spark: 214.4
Gluten version: 1.6.0
Spark version: 3.5.8

Gluten version

No response

Spark version

None

Spark configurations

spark.sql.decimalOperations.allowPrecisionLoss=false
when spark.sql.decimalOperations.allowPrecisionLoss=true; Gluten will return right result.

System information

No response

Relevant logs

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtriage

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions