Skip to content

Optimize load data assignment expressions #46081

@gengliqi

Description

@gengliqi

Enhancement

image

According to the above CPU flame graph, most of the time spends on rewriteAstExpr.
The root cause is that the ASTs of assignment expressions in load data are rewritten for each row, which may make the load data super slow.

#43492 has already fixed this issue, but only the TiDB clusters whose versions are greater than or equal to v7.2 contain this pr. In addition, there are some PR for load data code refactoring in v7.1.

So a tiny fix for this issue is needed for the previous TiDB version.

Metadata

Metadata

Assignees

No one assigned

    Labels

    affects-6.5This bug affects the 6.5.x(LTS) versions.affects-7.1This bug affects the 7.1.x(LTS) versions.sig/executionSIG executiontype/enhancementThe issue or PR belongs to an enhancement.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions