Skip to content

Divide-and-conquer strategy for intersections of unions - #57871

Merged
Anders Hejlsberg (ahejlsberg) merged 7 commits into
mainfrom
fix57863
Mar 21, 2024
Merged

Divide-and-conquer strategy for intersections of unions#57871
Anders Hejlsberg (ahejlsberg) merged 7 commits into
mainfrom
fix57863

Conversation

@ahejlsberg

@ahejlsbergAnders Hejlsberg (ahejlsberg) commented Mar 21, 2024

Copy link
Copy Markdown
Member

With this PR we implement a "divide and conquer" strategy for handling large intersections of union types. Specifically, when creating an intersection with four or more constituents, some of which are unions, we divide the constituents into two groups such that A & B & C & D is processed as (A & B) & (C & D). Since intersections of unions often produce far smaller unions of intersections than the full cartesian product (due to some intersections becoming never), this can dramatically reduce the overall work at the cost of generating slightly more types (because of the temporary intersections). For example, the reduced repro from #57863 that barely passes before this PR takes 0.28s to type check. That drops to 0.08s with this PR.

Fixes#57863.

@ahejlsberg

Copy link
Copy Markdown
MemberAuthor

@typescript-bot

TypeScript Bot (typescript-bot) commented Mar 21, 2024

Copy link
Copy Markdown
Contributor

Starting jobs; this comment will be updated as builds start and complete.

CommandStatusResults
test top200✅ Started✅ Results
user test this✅ Started✅ Results
run dt✅ Started
perf test this faster✅ Started👀 Results

@typescript-bot

Copy link
Copy Markdown
Contributor

Anders Hejlsberg (@ahejlsberg) Here are the results of running the user test suite comparing main and refs/pull/57871/merge:

Everything looks good!

@typescript-bot

Copy link
Copy Markdown
Contributor

Anders Hejlsberg (@ahejlsberg)
The results of the perf run you requested are in!

Here they are:

tsc

Comparison Report - baseline..pr
MetricbaselineprDeltaBestWorstp-value
Angular - node (v18.15.0, x64)
Memory used295,627k (± 0.01%)295,592k (± 0.01%)-35k (- 0.01%)295,561k295,611kp=0.031 n=6
Parse Time2.66s (± 0.15%)2.66s (± 0.28%)~2.65s2.67sp=1.000 n=6
Bind Time0.83s (± 0.00%)0.83s (± 0.66%)~0.82s0.83sp=0.071 n=6
Check Time8.22s (± 0.32%)8.21s (± 0.31%)~8.18s8.24sp=1.000 n=6
Emit Time7.04s (± 0.39%)7.03s (± 0.32%)~7.01s7.07sp=0.570 n=6
Total Time18.75s (± 0.19%)18.74s (± 0.14%)~18.70s18.77sp=0.418 n=6
Compiler-Unions - node (v18.15.0, x64)
Memory used192,618k (± 0.76%)192,528k (± 0.73%)~191,872k195,396kp=0.575 n=6
Parse Time1.36s (± 0.80%)1.36s (± 1.23%)~1.34s1.38sp=0.867 n=6
Bind Time0.72s (± 0.00%)0.72s (± 0.00%)~0.72s0.72sp=1.000 n=6
Check Time9.49s (± 1.04%)9.50s (± 0.73%)~9.43s9.60sp=0.810 n=6
Emit Time2.63s (± 0.70%)2.63s (± 0.37%)~2.62s2.64sp=0.730 n=6
Total Time14.21s (± 0.76%)14.21s (± 0.43%)~14.14s14.30sp=0.688 n=6
Monaco - node (v18.15.0, x64)
Memory used347,361k (± 0.00%)347,378k (± 0.00%)~347,367k347,389kp=0.054 n=6
Parse Time2.49s (± 0.16%)2.49s (± 0.33%)~2.48s2.50sp=0.584 n=6
Bind Time0.93s (± 0.44%)0.93s (± 0.44%)~0.92s0.93sp=1.000 n=6
Check Time7.00s (± 0.37%)7.03s (± 0.43%)~6.99s7.06sp=0.107 n=6
Emit Time4.08s (± 0.57%)4.06s (± 0.22%)-0.03s (- 0.61%)4.05s4.07sp=0.021 n=6
Total Time14.50s (± 0.25%)14.50s (± 0.14%)~14.47s14.53sp=0.872 n=6
TFS - node (v18.15.0, x64)
Memory used302,726k (± 0.01%)302,721k (± 0.01%)~302,675k302,761kp=0.936 n=6
Parse Time2.01s (± 1.18%)2.02s (± 0.58%)~2.00s2.03sp=0.625 n=6
Bind Time1.01s (± 1.02%)1.00s (± 0.52%)~0.99s1.00sp=0.069 n=6
Check Time6.32s (± 0.23%)6.33s (± 0.62%)~6.29s6.39sp=0.935 n=6
Emit Time3.60s (± 0.42%)3.60s (± 0.29%)~3.59s3.62sp=0.406 n=6
Total Time12.93s (± 0.19%)12.95s (± 0.35%)~12.89s13.02sp=0.469 n=6
material-ui - node (v18.15.0, x64)
Memory used509,875k (± 0.00%)509,899k (± 0.01%)~509,841k510,018kp=0.810 n=6
Parse Time2.65s (± 0.70%)2.66s (± 0.61%)~2.63s2.68sp=0.498 n=6
Bind Time0.99s (± 1.38%)0.99s (± 0.52%)~0.98s0.99sp=0.504 n=6
Check Time17.25s (± 0.36%)17.26s (± 0.51%)~17.12s17.35sp=1.000 n=6
Emit Time0.00s (± 0.00%)0.00s (± 0.00%)~0.00s0.00sp=1.000 n=6
Total Time20.88s (± 0.31%)20.90s (± 0.45%)~20.77s21.02sp=0.936 n=6
mui-docs - node (v18.15.0, x64)
Memory used1,719,659k (± 0.00%)1,737,371k (± 0.00%)+17,712k (+ 1.03%)1,737,338k1,737,411kp=0.005 n=6
Parse Time6.57s (± 0.40%)6.59s (± 0.72%)~6.55s6.68sp=0.935 n=6
Bind Time2.35s (± 0.32%)2.36s (± 0.58%)~2.35s2.38sp=0.149 n=6
Check Time56.22s (± 0.24%)56.32s (± 0.25%)~56.14s56.48sp=0.575 n=6
Emit Time0.13s (± 3.10%)0.14s (± 4.05%)~0.13s0.14sp=0.282 n=6
Total Time65.28s (± 0.19%)65.40s (± 0.26%)~65.18s65.59sp=0.520 n=6
self-build-src - node (v18.15.0, x64)
Memory used2,392,230k (± 0.03%)2,391,836k (± 0.03%)~2,390,583k2,392,691kp=0.378 n=6
Parse Time5.00s (± 1.42%)5.01s (± 1.57%)~4.88s5.09sp=0.689 n=6
Bind Time1.90s (± 0.99%)1.89s (± 1.02%)~1.87s1.92sp=0.808 n=6
Check Time33.58s (± 0.34%)33.69s (± 0.30%)~33.57s33.87sp=0.173 n=6
Emit Time2.62s (± 1.76%)2.63s (± 1.47%)~2.56s2.67sp=0.573 n=6
Total Time43.12s (± 0.45%)43.25s (± 0.17%)~43.18s43.34sp=0.128 n=6
self-compiler - node (v18.15.0, x64)
Memory used415,116k (± 0.01%)415,119k (± 0.01%)~415,083k415,160kp=0.630 n=6
Parse Time2.83s (± 0.58%)2.84s (± 0.65%)~2.82s2.87sp=0.560 n=6
Bind Time1.07s (± 0.38%)1.08s (± 0.51%)~1.07s1.08sp=0.282 n=6
Check Time15.32s (± 0.26%)15.30s (± 0.32%)~15.24s15.36sp=0.686 n=6
Emit Time1.11s (± 0.47%)1.11s (± 0.68%)~1.10s1.12sp=0.241 n=6
Total Time20.33s (± 0.29%)20.33s (± 0.31%)~20.24s20.38sp=0.872 n=6
vscode - node (v18.15.0, x64)
Memory used2,887,899k (± 0.00%)2,887,877k (± 0.00%)~2,887,763k2,887,996kp=0.748 n=6
Parse Time10.84s (± 0.32%)10.84s (± 0.17%)~10.81s10.86sp=0.511 n=6
Bind Time3.47s (± 0.68%)3.46s (± 0.38%)~3.44s3.48sp=0.869 n=6
Check Time61.41s (± 0.48%)61.81s (± 0.33%)+0.41s (+ 0.66%)61.55s62.04sp=0.030 n=6
Emit Time16.38s (± 0.44%)17.02s (± 8.11%)~16.35s19.84sp=0.065 n=6
Total Time92.10s (± 0.38%)93.15s (± 1.57%)+1.05s (+ 1.14%)92.39s96.11sp=0.013 n=6
webpack - node (v18.15.0, x64)
Memory used408,023k (± 0.01%)408,046k (± 0.01%)~407,998k408,158kp=0.575 n=6
Parse Time3.21s (± 0.51%)3.22s (± 0.60%)~3.20s3.25sp=0.807 n=6
Bind Time1.38s (± 0.71%)1.38s (± 0.85%)~1.36s1.39sp=1.000 n=6
Check Time14.26s (± 0.26%)14.28s (± 0.26%)~14.24s14.34sp=0.413 n=6
Emit Time0.00s (± 0.00%)0.00s (± 0.00%)~0.00s0.00sp=1.000 n=6
Total Time18.86s (± 0.16%)18.89s (± 0.15%)~18.85s18.92sp=0.124 n=6
xstate - node (v18.15.0, x64)
Memory used512,961k (± 0.01%)513,044k (± 0.01%)~512,964k513,118kp=0.093 n=6
Parse Time3.28s (± 0.23%)3.28s (± 0.19%)~3.27s3.29sp=0.718 n=6
Bind Time1.54s (± 0.64%)1.54s (± 0.34%)~1.53s1.54sp=0.504 n=6
Check Time2.85s (± 0.53%)2.85s (± 0.22%)~2.84s2.86sp=0.739 n=6
Emit Time0.07s (± 0.00%)0.07s (± 0.00%)~0.07s0.07sp=1.000 n=6
Total Time7.74s (± 0.24%)7.75s (± 0.16%)~7.73s7.76sp=0.519 n=6
System info unknown
Hosts
  • node (v18.15.0, x64)
Scenarios
  • Angular - node (v18.15.0, x64)
  • Compiler-Unions - node (v18.15.0, x64)
  • Monaco - node (v18.15.0, x64)
  • TFS - node (v18.15.0, x64)
  • material-ui - node (v18.15.0, x64)
  • mui-docs - node (v18.15.0, x64)
  • self-build-src - node (v18.15.0, x64)
  • self-compiler - node (v18.15.0, x64)
  • vscode - node (v18.15.0, x64)
  • webpack - node (v18.15.0, x64)
  • xstate - node (v18.15.0, x64)
BenchmarkNameIterations
Currentpr6
Baselinebaseline6

Developer Information:

Download Benchmarks

@typescript-bot

Copy link
Copy Markdown
Contributor

Anders Hejlsberg (@ahejlsberg) Here are the results of running the top-repos suite comparing main and refs/pull/57871/merge:

Everything looks good!

@ahejlsberg

Copy link
Copy Markdown
MemberAuthor

@typescript-bot

TypeScript Bot (typescript-bot) commented Mar 21, 2024

Copy link
Copy Markdown
Contributor

Starting jobs; this comment will be updated as builds start and complete.

CommandStatusResults
run dt✅ Started👀 Results
perf test this faster✅ Started👀 Results

@typescript-bot

Copy link
Copy Markdown
Contributor

Hey Anders Hejlsberg (@ahejlsberg), the results of running the DT tests are ready.
There were interesting changes:

Branch only errors:

Package: amap-js-api-driving
Error:

Error: /mnt/vss/_work/1/DefinitelyTyped/types/amap-js-api-driving/amap-js-api-driving-tests.ts
162:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
166:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
✖ 2 problems (2 errors, 0 warnings)
at combineErrorsAndWarnings (/mnt/vss/_work/1/DefinitelyTyped/node_modules/.pnpm/@definitelytyped+dtslint@0.2.18_typescript@5.5.0-dev.20240321/node_modules/@definitelytyped/dtslint/dist/index.js:194:28)
at runTests (/mnt/vss/_work/1/DefinitelyTyped/node_modules/.pnpm/@definitelytyped+dtslint@0.2.18_typescript@5.5.0-dev.20240321/node_modules/@definitelytyped/dtslint/dist/index.js:186:20)

Package: amap-js-api-riding
Error:

Error: /mnt/vss/_work/1/DefinitelyTyped/types/amap-js-api-riding/amap-js-api-riding-tests.ts
100:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
110:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
145:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
149:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
✖ 4 problems (4 errors, 0 warnings)
at combineErrorsAndWarnings (/mnt/vss/_work/1/DefinitelyTyped/node_modules/.pnpm/@definitelytyped+dtslint@0.2.18_typescript@5.5.0-dev.20240321/node_modules/@definitelytyped/dtslint/dist/index.js:194:28)
at runTests (/mnt/vss/_work/1/DefinitelyTyped/node_modules/.pnpm/@definitelytyped+dtslint@0.2.18_typescript@5.5.0-dev.20240321/node_modules/@definitelytyped/dtslint/dist/index.js:186:20)

Package: amap-js-api-transfer
Error:

Error: /mnt/vss/_work/1/DefinitelyTyped/types/amap-js-api-transfer/amap-js-api-transfer-tests.ts
321:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
325:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
351:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
353:9 error TypeScript@local expected type to be:
PoiExt
got:
PoiBase & { website: string; pcode: string; citycode: string; adcode: string; postcode: string; pname: string; cityname: string; adname: string; email: string; photos: PoiPhoto[]; entr_location: LngLat | null; exit_location: LngLat | null; groupbuy: boolean; discount: boolean; } & (({ indoor_map: true; indoor_data: { cpid: string; floor: string; truefloor: string; }; } | { indoor_map: false; }) & { groupbuys?: Groupbuy[] | undefined; discounts?: Discount[] | undefined; } & ({ deep_type: "CINEMA"; cinema: Cinema; } | { deep_type: "DINING"; dining: Dining; } | { deep_type: "SCENIC"; scenic: Scenic; } | { deep_type: "HOTEL"; hotel: Hotel; })) @definitelytyped/expect
✖ 4 problems (4 errors, 0 warnings)
at combineErrorsAndWarnings (/mnt/vss/_work/1/DefinitelyTyped/node_modules/.pnpm/@definitelytyped+dtslint@0.2.18_typescript@5.5.0-dev.20240321/node_modules/@definitelytyped/dtslint/dist/index.js:194:28)
at runTests (/mnt/vss/_work/1/DefinitelyTyped/node_modules/.pnpm/@definitelytyped+dtslint@0.2.18_typescript@5.5.0-dev.20240321/node_modules/@definitelytyped/dtslint/dist/index.js:186:20)

You can check the log here.

@typescript-bot

Copy link
Copy Markdown
Contributor

Anders Hejlsberg (@ahejlsberg)
The results of the perf run you requested are in!

Here they are:

tsc

Comparison Report - baseline..pr
MetricbaselineprDeltaBestWorstp-value
Angular - node (v18.15.0, x64)
Memory used295,609k (± 0.00%)295,633k (± 0.00%)+24k (+ 0.01%)295,622k295,654kp=0.013 n=6
Parse Time2.67s (± 0.44%)2.67s (± 0.31%)~2.66s2.68sp=0.555 n=6
Bind Time0.83s (± 0.62%)0.83s (± 0.49%)~0.82s0.83sp=0.595 n=6
Check Time8.22s (± 0.22%)8.20s (± 0.39%)~8.17s8.26sp=0.077 n=6
Emit Time7.03s (± 0.30%)7.06s (± 0.77%)~7.01s7.14sp=0.517 n=6
Total Time18.75s (± 0.16%)18.75s (± 0.35%)~18.67s18.82sp=0.872 n=6
Compiler-Unions - node (v18.15.0, x64)
Memory used193,097k (± 0.97%)192,460k (± 0.74%)~191,814k195,381kp=0.298 n=6
Parse Time1.35s (± 1.58%)1.36s (± 1.42%)~1.34s1.39sp=0.370 n=6
Bind Time0.72s (± 0.00%)0.72s (± 0.00%)~0.72s0.72sp=1.000 n=6
Check Time9.49s (± 0.71%)9.49s (± 0.76%)~9.43s9.61sp=1.000 n=6
Emit Time2.65s (± 0.50%)2.64s (± 0.75%)~2.61s2.66sp=0.287 n=6
Total Time14.21s (± 0.33%)14.21s (± 0.56%)~14.13s14.34sp=0.688 n=6
Monaco - node (v18.15.0, x64)
Memory used347,371k (± 0.00%)347,385k (± 0.01%)~347,364k347,417kp=0.261 n=6
Parse Time2.49s (± 0.30%)2.49s (± 0.70%)~2.47s2.52sp=0.397 n=6
Bind Time0.92s (± 0.56%)0.93s (± 0.56%)~0.92s0.93sp=0.311 n=6
Check Time7.02s (± 0.70%)7.03s (± 0.29%)~6.99s7.05sp=1.000 n=6
Emit Time4.06s (± 0.27%)4.07s (± 0.39%)~4.05s4.09sp=0.410 n=6
Total Time14.49s (± 0.38%)14.51s (± 0.27%)~14.44s14.56sp=0.744 n=6
TFS - node (v18.15.0, x64)
Memory used302,716k (± 0.01%)302,732k (± 0.00%)~302,718k302,740kp=0.108 n=6
Parse Time2.02s (± 0.51%)2.01s (± 0.80%)~1.99s2.03sp=0.623 n=6
Bind Time1.00s (± 0.82%)1.00s (± 0.63%)~0.99s1.01sp=0.432 n=6
Check Time6.31s (± 0.43%)6.30s (± 0.16%)~6.29s6.32sp=0.618 n=6
Emit Time3.60s (± 0.15%)3.61s (± 0.39%)~3.59s3.63sp=0.498 n=6
Total Time12.93s (± 0.20%)12.93s (± 0.14%)~12.91s12.95sp=0.935 n=6
material-ui - node (v18.15.0, x64)
Memory used509,886k (± 0.00%)509,866k (± 0.00%)~509,837k509,900kp=0.230 n=6
Parse Time2.66s (± 0.37%)2.66s (± 0.66%)~2.63s2.68sp=0.869 n=6
Bind Time0.98s (± 0.85%)0.98s (± 0.85%)~0.98s1.00sp=1.000 n=6
Check Time17.24s (± 0.21%)17.26s (± 0.38%)~17.17s17.33sp=0.519 n=6
Emit Time0.00s (± 0.00%)0.00s (± 0.00%)~0.00s0.00sp=1.000 n=6
Total Time20.88s (± 0.19%)20.90s (± 0.28%)~20.81s20.97sp=0.686 n=6
mui-docs - node (v18.15.0, x64)
Memory used1,719,639k (± 0.00%)1,737,399k (± 0.00%)+17,761k (+ 1.03%)1,737,366k1,737,442kp=0.005 n=6
Parse Time6.59s (± 0.21%)6.58s (± 0.56%)~6.54s6.62sp=0.806 n=6
Bind Time2.35s (± 0.42%)2.36s (± 0.35%)~2.35s2.37sp=0.282 n=6
Check Time56.26s (± 0.33%)56.50s (± 0.46%)~56.25s56.96sp=0.149 n=6
Emit Time0.13s (± 3.10%)0.13s (± 3.87%)~0.13s0.14sp=0.595 n=6
Total Time65.33s (± 0.27%)65.57s (± 0.43%)~65.28s66.07sp=0.173 n=6
self-build-src - node (v18.15.0, x64)
Memory used2,392,082k (± 0.03%)2,392,015k (± 0.04%)~2,391,224k2,393,568kp=0.936 n=6
Parse Time5.05s (± 1.22%)5.01s (± 0.99%)~4.92s5.06sp=0.521 n=6
Bind Time1.90s (± 0.72%)1.91s (± 0.80%)~1.88s1.92sp=0.868 n=6
Check Time33.60s (± 0.33%)33.55s (± 0.21%)~33.48s33.66sp=0.575 n=6
Emit Time2.62s (± 1.65%)2.63s (± 2.09%)~2.55s2.70sp=0.687 n=6
Total Time43.20s (± 0.41%)43.11s (± 0.30%)~42.95s43.31sp=0.471 n=6
self-compiler - node (v18.15.0, x64)
Memory used415,083k (± 0.01%)415,101k (± 0.01%)~415,045k415,174kp=0.575 n=6
Parse Time2.82s (± 1.23%)2.84s (± 0.85%)~2.80s2.86sp=0.466 n=6
Bind Time1.08s (± 0.78%)1.07s (± 0.70%)~1.06s1.08sp=0.432 n=6
Check Time15.28s (± 0.38%)15.28s (± 0.20%)~15.23s15.31sp=0.936 n=6
Emit Time1.11s (± 1.23%)1.11s (± 0.74%)~1.10s1.12sp=0.445 n=6
Total Time20.29s (± 0.41%)20.29s (± 0.15%)~20.25s20.34sp=0.936 n=6
vscode - node (v18.15.0, x64)
Memory used2,888,153k (± 0.00%)2,888,152k (± 0.00%)~2,888,095k2,888,237kp=0.810 n=6
Parse Time10.82s (± 0.27%)10.85s (± 0.43%)~10.81s10.94sp=0.257 n=6
Bind Time3.47s (± 0.65%)3.46s (± 0.30%)~3.44s3.47sp=0.139 n=6
Check Time61.63s (± 0.24%)61.66s (± 0.44%)~61.43s62.16sp=0.810 n=6
Emit Time16.51s (± 0.66%)16.46s (± 1.00%)~16.32s16.75sp=0.261 n=6
Total Time92.44s (± 0.29%)92.43s (± 0.28%)~92.18s92.81sp=0.936 n=6
webpack - node (v18.15.0, x64)
Memory used408,137k (± 0.02%)408,140k (± 0.02%)~408,064k408,245kp=0.936 n=6
Parse Time3.25s (± 0.30%)3.25s (± 0.23%)~3.24s3.26sp=0.858 n=6
Bind Time1.38s (± 0.60%)1.38s (± 0.30%)~1.38s1.39sp=0.527 n=6
Check Time14.27s (± 0.18%)14.25s (± 0.28%)~14.20s14.29sp=0.627 n=6
Emit Time0.00s (± 0.00%)0.00s (± 0.00%)~0.00s0.00sp=1.000 n=6
Total Time18.90s (± 0.17%)18.88s (± 0.23%)~18.83s18.93sp=0.517 n=6
xstate - node (v18.15.0, x64)
Memory used513,026k (± 0.01%)513,021k (± 0.01%)~512,915k513,107kp=0.688 n=6
Parse Time3.28s (± 0.30%)3.29s (± 0.42%)~3.26s3.30sp=0.315 n=6
Bind Time1.54s (± 0.00%)1.54s (± 0.35%)~1.54s1.55sp=0.071 n=6
Check Time2.85s (± 0.48%)2.85s (± 0.42%)~2.83s2.86sp=1.000 n=6
Emit Time0.07s (± 0.00%)0.07s (± 5.69%)~0.07s0.08sp=0.405 n=6
Total Time7.74s (± 0.27%)7.74s (± 0.25%)~7.71s7.76sp=0.936 n=6
System info unknown
Hosts
  • node (v18.15.0, x64)
Scenarios
  • Angular - node (v18.15.0, x64)
  • Compiler-Unions - node (v18.15.0, x64)
  • Monaco - node (v18.15.0, x64)
  • TFS - node (v18.15.0, x64)
  • material-ui - node (v18.15.0, x64)
  • mui-docs - node (v18.15.0, x64)
  • self-build-src - node (v18.15.0, x64)
  • self-compiler - node (v18.15.0, x64)
  • vscode - node (v18.15.0, x64)
  • webpack - node (v18.15.0, x64)
  • xstate - node (v18.15.0, x64)
BenchmarkNameIterations
Currentpr6
Baselinebaseline6

Developer Information:

Download Benchmarks

@ahejlsberg

Copy link
Copy Markdown
MemberAuthor

@typescript-bot

TypeScript Bot (typescript-bot) commented Mar 21, 2024

Copy link
Copy Markdown
Contributor

Starting jobs; this comment will be updated as builds start and complete.

CommandStatusResults
run dt✅ Started✅ Results

@typescript-bot

Copy link
Copy Markdown
Contributor

Hey Anders Hejlsberg (@ahejlsberg), the results of running the DT tests are ready.
Everything looks the same!
You can check the log here.

@ahejlsberg

Copy link
Copy Markdown
MemberAuthor

Tests and performance are unaffected. This is ready for a review.

Comment threadsrc/compiler/checker.ts Outdated
@jakebailey

Copy link
Copy Markdown
Member

TypeScript Bot (@typescript-bot) cherry-pick this to release-5.4

@typescript-bot

TypeScript Bot (typescript-bot) commented Mar 21, 2024

Copy link
Copy Markdown
Contributor

Starting jobs; this comment will be updated as builds start and complete.

CommandStatusResults
cherry-pick this to release-5.4✅ Started❌ Results

@typescript-bot

Copy link
Copy Markdown
Contributor

Hey, Jake Bailey (@jakebailey)! I was unable to cherry-pick this PR.

Check the logs at: https://github.com/microsoft/TypeScript/actions/runs/8380435679

@jakebailey

Copy link
Copy Markdown
Member

TypeScript Bot (@typescript-bot) cherry-pick this to release-5.4

@typescript-bot

TypeScript Bot (typescript-bot) commented Mar 21, 2024

Copy link
Copy Markdown
Contributor

Starting jobs; this comment will be updated as builds start and complete.

CommandStatusResults
cherry-pick this to release-5.4✅ Started✅ Results

@typescript-bot

Copy link
Copy Markdown
Contributor

Hey, Jake Bailey (@jakebailey)! I've created #57893 for you. This involved updating baselines; please check the diff.

@KnorpelSenf

Copy link
Copy Markdown

This is huge, thank you so much! I've been working around this limitation in my library for almost a year now. These changes allow me to do so much more now! 🎉❤️

@KnorpelSenf

Copy link
Copy Markdown

Anders Hejlsberg (@ahejlsberg) I would like to see a patch release on top of 5.4 with these changes. Is there anything I can do to help get this out there?

@jakebailey

Copy link
Copy Markdown
Member

This is backported (see above), and will be in the next patch.

Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Author: TeamFor Uncommitted BugPR for untriaged, rejected, closed or missing bug

Projects

None yet

5 participants

@ahejlsberg@typescript-bot@jakebailey@KnorpelSenf@RyanCavanaugh