You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
tsc -b no-op build ~5x slower in 7.1.0-beta (isContentMapperSupplementalBuildInfoPath scans every root per file) #64897
This changed between versions 7.0.2 and 7.1.0-beta
This changed in commit or PR Content mappers typescript-go#4712 (content mappers), which added isContentMapperSupplementalBuildInfoPath. main still has the same code
on our app (private, ~20.8k files in the program, most of them .d.ts under node_modules) the second run says Project 'tsconfig.json' is up to date, Files: 0, and still takes 4.7s wall / 7.4s user. 7.0.2 does the same no-op in 1.0s / 0.24s user.
median of 5 runs each: 1.28s on 7.0.2 vs 6.49s on 7.1.0-beta. a smaller service (~11k files) goes 0.82s -> 1.74s
cpu profile of the no-op run on 7.1.0-beta (--pprofDir, go tool pprof -top -cum):
getUpToDateStatus calls isContentMapperSupplementalBuildInfoPath for every non-root file in buildInfo.FileInfos, and that ranges over all the roots building string(root)+"." each time - so files x roots string allocations, plus the GC work on top. none of our files are content mapper outputs and we don't use content mappers at all
a no-op build about as fast as on 7.0.2. maybe skip the check when no content mapper is configured, or build the root lookup once per project instead of scanning every root for every file
Activity