Skip to content

[fix](predicate) Avoid recomputing predicates#60484

Merged
Gabriel39 merged 1 commit intoapache:masterfrom
Gabriel39:fix_0204
Feb 5, 2026
Merged

[fix](predicate) Avoid recomputing predicates#60484
Gabriel39 merged 1 commit intoapache:masterfrom
Gabriel39:fix_0204

Conversation

@Gabriel39
Copy link
Contributor

What problem does this PR solve?

Issue Number: close #xxx

Related PR: #xxx

Problem Summary:

Release note

None

Check List (For Author)

  • Test

    • Regression test
    • Unit Test
    • Manual test (add detailed scripts or steps below)
    • No need to test or manual test. Explain why:
      • This is a refactor/code format and no logic has been changed.
      • Previous test can cover this change.
      • No code files have been changed.
      • Other reason
  • Behavior changed:

    • No.
    • Yes.
  • Does this need documentation?

    • No.
    • Yes.

Check List (For Reviewer who merge this PR)

  • Confirm the release note
  • Confirm test cases
  • Confirm document
  • Add branch pick label

@Thearas
Copy link
Contributor

Thearas commented Feb 4, 2026

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR.

Please clearly describe your PR:

  1. What problem was fixed (it's best to include specific error reporting information). How it was fixed.
  2. Which behaviors were modified. What was the previous behavior, what is it now, why was it modified, and what possible impacts might there be.
  3. What features were added. Why was this function added?
  4. Which code was refactored and why was this part of the code refactored?
  5. Which functions were optimized and what is the difference before and after the optimization?

@Gabriel39
Copy link
Contributor Author

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 31267 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit fca4152d6e965afb2dba0fa92f370933a7075044, data reload: false

------ Round 1 ----------------------------------
q1	17648	4576	4347	4347
q2	2043	320	193	193
q3	10203	1279	713	713
q4	10217	913	316	316
q5	7543	2191	1936	1936
q6	199	176	147	147
q7	867	720	601	601
q8	9288	1395	1101	1101
q9	5476	4896	4922	4896
q10	6859	1976	1562	1562
q11	510	324	271	271
q12	374	374	221	221
q13	17815	4117	3239	3239
q14	248	250	215	215
q15	929	827	795	795
q16	692	689	625	625
q17	660	827	495	495
q18	7517	6556	6434	6434
q19	1694	991	626	626
q20	378	344	229	229
q21	2612	2022	2072	2022
q22	363	319	283	283
Total cold run time: 104135 ms
Total hot run time: 31267 ms

----- Round 2, with runtime_filter_mode=off -----
q1	4461	4378	4400	4378
q2	257	358	255	255
q3	2110	2616	2229	2229
q4	1349	1706	1267	1267
q5	4308	4170	4238	4170
q6	223	179	136	136
q7	1883	1773	2185	1773
q8	2648	2560	2439	2439
q9	7640	7618	7453	7453
q10	2873	3184	2595	2595
q11	561	481	454	454
q12	707	783	625	625
q13	3871	4392	3651	3651
q14	283	316	288	288
q15	921	848	835	835
q16	731	726	668	668
q17	1130	1281	1298	1281
q18	8119	7902	7837	7837
q19	895	845	837	837
q20	2042	2130	1937	1937
q21	4936	4624	4131	4131
q22	578	566	519	519
Total cold run time: 52526 ms
Total hot run time: 49758 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 28.22 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit fca4152d6e965afb2dba0fa92f370933a7075044, data reload: false

query1	0.05	0.04	0.05
query2	0.10	0.04	0.04
query3	0.25	0.09	0.08
query4	1.60	0.11	0.11
query5	0.26	0.25	0.24
query6	1.17	0.70	0.68
query7	0.03	0.03	0.03
query8	0.05	0.04	0.04
query9	0.57	0.50	0.49
query10	0.55	0.56	0.54
query11	0.14	0.10	0.10
query12	0.14	0.10	0.10
query13	0.63	0.61	0.61
query14	1.09	1.07	1.05
query15	0.88	0.85	0.87
query16	0.39	0.39	0.38
query17	1.08	1.17	1.13
query18	0.22	0.21	0.21
query19	2.11	1.99	2.06
query20	0.02	0.02	0.01
query21	15.42	0.28	0.14
query22	5.10	0.06	0.04
query23	15.95	0.30	0.09
query24	1.05	0.72	0.31
query25	0.09	0.06	0.09
query26	0.15	0.13	0.14
query27	0.06	0.04	0.04
query28	3.29	1.15	0.95
query29	12.58	3.90	3.15
query30	0.27	0.14	0.12
query31	2.82	0.64	0.40
query32	3.23	0.60	0.50
query33	3.37	3.23	3.23
query34	16.19	5.33	4.72
query35	4.76	4.74	4.81
query36	0.65	0.50	0.50
query37	0.10	0.08	0.07
query38	0.07	0.04	0.04
query39	0.04	0.02	0.02
query40	0.19	0.16	0.16
query41	0.09	0.04	0.03
query42	0.04	0.03	0.03
query43	0.05	0.04	0.03
Total cold run time: 96.89 s
Total hot run time: 28.22 s

@Gabriel39
Copy link
Contributor Author

run buildall

@Gabriel39
Copy link
Contributor Author

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 31183 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 14a731ece0e662e90b7015a21e6589a262c76e2b, data reload: false

------ Round 1 ----------------------------------
q1	17632	4475	4293	4293
q2	2058	322	222	222
q3	10155	1306	738	738
q4	10212	876	328	328
q5	7540	2139	1960	1960
q6	191	176	145	145
q7	873	735	580	580
q8	9265	1387	1151	1151
q9	5204	4883	4835	4835
q10	6814	1932	1561	1561
q11	482	298	287	287
q12	346	379	230	230
q13	17772	4081	3282	3282
q14	234	243	210	210
q15	907	821	793	793
q16	691	664	629	629
q17	648	821	487	487
q18	6837	6655	6378	6378
q19	1233	995	626	626
q20	373	342	220	220
q21	2684	2112	1955	1955
q22	360	323	273	273
Total cold run time: 102511 ms
Total hot run time: 31183 ms

----- Round 2, with runtime_filter_mode=off -----
q1	4357	4356	4357	4356
q2	247	337	247	247
q3	2120	2601	2228	2228
q4	1359	1738	1293	1293
q5	4281	4222	4405	4222
q6	199	173	138	138
q7	1872	1785	1707	1707
q8	2819	2554	2503	2503
q9	7520	7453	7540	7453
q10	2744	3220	2576	2576
q11	547	488	469	469
q12	778	739	645	645
q13	3940	4312	3549	3549
q14	316	320	307	307
q15	911	795	800	795
q16	680	736	703	703
q17	1209	1359	1344	1344
q18	8300	7864	7962	7864
q19	926	966	892	892
q20	2020	2123	2048	2048
q21	4818	4637	4395	4395
q22	597	555	512	512
Total cold run time: 52560 ms
Total hot run time: 50246 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 28.28 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 14a731ece0e662e90b7015a21e6589a262c76e2b, data reload: false

query1	0.06	0.05	0.05
query2	0.09	0.05	0.05
query3	0.27	0.09	0.08
query4	1.61	0.11	0.12
query5	0.27	0.24	0.24
query6	1.16	0.68	0.66
query7	0.03	0.03	0.02
query8	0.05	0.04	0.04
query9	0.58	0.50	0.49
query10	0.55	0.54	0.54
query11	0.15	0.10	0.10
query12	0.13	0.10	0.10
query13	0.63	0.61	0.62
query14	1.08	1.08	1.04
query15	0.89	0.86	0.88
query16	0.40	0.40	0.42
query17	1.15	1.13	1.14
query18	0.23	0.21	0.21
query19	2.04	2.05	2.07
query20	0.02	0.02	0.01
query21	15.39	0.26	0.14
query22	5.15	0.04	0.04
query23	15.97	0.28	0.11
query24	1.89	0.24	0.38
query25	0.09	0.07	0.05
query26	0.14	0.13	0.14
query27	0.08	0.07	0.08
query28	3.55	1.15	0.98
query29	12.59	3.89	3.13
query30	0.28	0.14	0.11
query31	2.81	0.64	0.40
query32	3.23	0.60	0.49
query33	3.24	3.24	3.29
query34	16.20	5.41	4.74
query35	4.85	4.77	4.80
query36	0.65	0.51	0.49
query37	0.10	0.07	0.06
query38	0.07	0.05	0.04
query39	0.04	0.03	0.04
query40	0.18	0.16	0.15
query41	0.08	0.03	0.03
query42	0.04	0.02	0.03
query43	0.04	0.03	0.04
Total cold run time: 98.05 s
Total hot run time: 28.28 s

@doris-robot
Copy link

BE UT Coverage Report

Increment line coverage 0.00% (0/28) 🎉

Increment coverage report
Complete coverage report

Category Coverage
Function Coverage 52.58% (19373/36844)
Line Coverage 36.05% (179965/499160)
Region Coverage 32.42% (139530/430425)
Branch Coverage 33.41% (60421/180833)

@Gabriel39
Copy link
Contributor Author

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 32253 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 150015e1046116f625eaf83e07067362743baa3d, data reload: false

------ Round 1 ----------------------------------
q1	17643	5273	5072	5072
q2	2092	360	233	233
q3	10098	1311	810	810
q4	10207	802	341	341
q5	7595	2205	1986	1986
q6	220	182	151	151
q7	887	740	614	614
q8	9276	1445	1125	1125
q9	5461	4863	4823	4823
q10	6910	1956	1579	1579
q11	541	308	288	288
q12	398	381	235	235
q13	17823	4110	3253	3253
q14	244	237	219	219
q15	959	824	832	824
q16	690	693	631	631
q17	677	835	497	497
q18	6784	6490	6590	6490
q19	1513	1010	639	639
q20	401	372	261	261
q21	2827	2200	1901	1901
q22	366	316	281	281
Total cold run time: 103612 ms
Total hot run time: 32253 ms

----- Round 2, with runtime_filter_mode=off -----
q1	5468	5314	5360	5314
q2	264	343	245	245
q3	2209	2685	2269	2269
q4	1370	1766	1321	1321
q5	4297	4153	4379	4153
q6	265	207	155	155
q7	2299	2001	1839	1839
q8	2626	2419	2459	2419
q9	7679	7404	7490	7404
q10	2969	3097	2700	2700
q11	578	485	441	441
q12	679	782	674	674
q13	4030	4494	3533	3533
q14	331	326	290	290
q15	860	846	817	817
q16	744	756	682	682
q17	1200	1394	1483	1394
q18	8160	8044	7815	7815
q19	964	886	975	886
q20	2068	2136	2056	2056
q21	4740	4290	4106	4106
q22	566	547	512	512
Total cold run time: 54366 ms
Total hot run time: 51025 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 28.54 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 150015e1046116f625eaf83e07067362743baa3d, data reload: false

query1	0.05	0.05	0.05
query2	0.10	0.05	0.05
query3	0.25	0.08	0.09
query4	1.60	0.11	0.11
query5	0.27	0.25	0.26
query6	1.16	0.69	0.68
query7	0.03	0.03	0.02
query8	0.06	0.04	0.04
query9	0.56	0.49	0.51
query10	0.55	0.55	0.54
query11	0.15	0.10	0.09
query12	0.14	0.11	0.11
query13	0.64	0.62	0.61
query14	1.07	1.07	1.06
query15	0.88	0.86	0.87
query16	0.40	0.39	0.38
query17	1.15	1.18	1.16
query18	0.23	0.21	0.21
query19	2.00	2.04	2.11
query20	0.02	0.02	0.01
query21	15.41	0.26	0.14
query22	5.25	0.06	0.05
query23	15.90	0.30	0.10
query24	2.09	0.53	0.27
query25	0.08	0.12	0.09
query26	0.14	0.14	0.13
query27	0.07	0.11	0.06
query28	4.30	1.15	0.97
query29	12.56	3.95	3.19
query30	0.28	0.13	0.12
query31	2.82	0.65	0.41
query32	3.23	0.60	0.49
query33	3.20	3.32	3.28
query34	16.20	5.34	4.76
query35	4.80	4.86	4.77
query36	0.67	0.49	0.50
query37	0.11	0.07	0.07
query38	0.08	0.04	0.04
query39	0.04	0.03	0.03
query40	0.19	0.16	0.15
query41	0.08	0.03	0.04
query42	0.05	0.03	0.04
query43	0.04	0.04	0.03
Total cold run time: 98.9 s
Total hot run time: 28.54 s

@hello-stephen
Copy link
Contributor

BE UT Coverage Report

Increment line coverage 0.00% (0/28) 🎉

Increment coverage report
Complete coverage report

Category Coverage
Function Coverage 52.55% (19370/36858)
Line Coverage 36.05% (179943/499207)
Region Coverage 32.41% (139518/430417)
Branch Coverage 33.41% (60416/180807)

@hello-stephen
Copy link
Contributor

BE Regression && UT Coverage Report

Increment line coverage 100.00% (28/28) 🎉

Increment coverage report
Complete coverage report

Category Coverage
Function Coverage 71.56% (25848/36122)
Line Coverage 54.19% (269888/498012)
Region Coverage 51.76% (225076/434833)
Branch Coverage 53.17% (96520/181537)

@Gabriel39
Copy link
Contributor Author

run buildall

@doris-robot
Copy link

TPC-H: Total hot run time: 31317 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 20cd78159aac713840999fd4aadc59cf269607a8, data reload: false

------ Round 1 ----------------------------------
q1	17628	4443	4291	4291
q2	2050	383	229	229
q3	10091	1273	734	734
q4	10230	929	325	325
q5	7528	2117	1975	1975
q6	193	181	146	146
q7	885	724	596	596
q8	9271	1459	1121	1121
q9	5276	4866	4858	4858
q10	6765	1979	1574	1574
q11	524	282	288	282
q12	337	381	225	225
q13	17786	4054	3251	3251
q14	238	235	232	232
q15	891	819	800	800
q16	685	686	618	618
q17	649	815	473	473
q18	6875	6468	7423	6468
q19	1286	1035	624	624
q20	402	388	257	257
q21	2970	2362	1952	1952
q22	355	319	286	286
Total cold run time: 102915 ms
Total hot run time: 31317 ms

----- Round 2, with runtime_filter_mode=off -----
q1	4572	4677	4577	4577
q2	282	351	264	264
q3	2319	2904	2421	2421
q4	1491	1867	1462	1462
q5	4734	4541	4448	4448
q6	224	186	142	142
q7	1946	2150	1730	1730
q8	2581	2450	2410	2410
q9	7710	7573	7491	7491
q10	2788	3030	2567	2567
q11	562	494	472	472
q12	708	775	640	640
q13	3937	4313	3475	3475
q14	289	301	284	284
q15	849	786	767	767
q16	632	679	640	640
q17	1105	1310	1308	1308
q18	7517	7480	7209	7209
q19	843	795	808	795
q20	1943	2009	1851	1851
q21	4524	4278	4119	4119
q22	616	542	496	496
Total cold run time: 52172 ms
Total hot run time: 49568 ms

@doris-robot
Copy link

ClickBench: Total hot run time: 28.35 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 20cd78159aac713840999fd4aadc59cf269607a8, data reload: false

query1	0.06	0.05	0.05
query2	0.09	0.05	0.05
query3	0.26	0.09	0.08
query4	1.61	0.10	0.11
query5	0.26	0.24	0.25
query6	1.16	0.69	0.67
query7	0.03	0.03	0.02
query8	0.05	0.03	0.04
query9	0.57	0.50	0.48
query10	0.55	0.55	0.53
query11	0.13	0.09	0.09
query12	0.13	0.10	0.10
query13	0.63	0.61	0.63
query14	1.06	1.07	1.06
query15	0.87	0.86	0.87
query16	0.40	0.40	0.39
query17	1.16	1.12	1.06
query18	0.23	0.21	0.20
query19	2.12	1.93	2.04
query20	0.01	0.01	0.01
query21	15.39	0.23	0.14
query22	5.39	0.06	0.05
query23	16.02	0.30	0.10
query24	0.97	0.50	0.62
query25	0.10	0.07	0.06
query26	0.14	0.14	0.14
query27	0.09	0.07	0.08
query28	5.08	1.15	0.96
query29	12.58	3.92	3.17
query30	0.27	0.12	0.10
query31	2.81	0.61	0.40
query32	3.25	0.60	0.50
query33	3.23	3.22	3.29
query34	16.03	5.47	4.75
query35	4.80	4.82	4.77
query36	0.65	0.49	0.48
query37	0.11	0.07	0.06
query38	0.07	0.04	0.05
query39	0.04	0.03	0.03
query40	0.18	0.17	0.16
query41	0.09	0.04	0.03
query42	0.04	0.03	0.03
query43	0.05	0.04	0.03
Total cold run time: 98.76 s
Total hot run time: 28.35 s

@doris-robot
Copy link

BE UT Coverage Report

Increment line coverage 0.00% (0/31) 🎉

Increment coverage report
Complete coverage report

Category Coverage
Function Coverage 52.55% (19370/36858)
Line Coverage 36.05% (179960/499226)
Region Coverage 32.41% (139495/430431)
Branch Coverage 33.41% (60417/180816)

@hello-stephen
Copy link
Contributor

BE Regression && UT Coverage Report

Increment line coverage 100.00% (31/31) 🎉

Increment coverage report
Complete coverage report

Category Coverage
Function Coverage 71.64% (25878/36122)
Line Coverage 54.27% (270302/498031)
Region Coverage 51.87% (225569/434847)
Branch Coverage 53.20% (96591/181546)

@shuke987
Copy link
Collaborator

shuke987 commented Feb 5, 2026

skip buildall

@github-actions
Copy link
Contributor

github-actions bot commented Feb 5, 2026

PR approved by anyone and no changes requested.

@Gabriel39 Gabriel39 merged commit 14c7b20 into apache:master Feb 5, 2026
30 of 32 checks passed
@github-actions github-actions bot added the approved Indicates a PR has been approved by one committer. label Feb 5, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Feb 5, 2026

PR approved by at least one committer and no changes requested.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by one committer. dev/4.0.4-merged reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants