Skip to content

Perf Regression - Excessive time spent in realpath in build mode #46204

Closed
@amcasey

Description

@amcasey

Profiling an internal codebase yielded the following

  637689ms 22.57% 22.57%   637689ms 22.57%  realpath
  500600ms 17.72% 40.29%   500736ms 17.72%  uvException internal/errors.js:402

The first line is self explanatory and the second suggests that a lot of those realpath calls are for non-existent paths.

The calls are coming from https://github.com/microsoft/TypeScript/pull/44935/files#diff-0558af289c76f66611354da63a14152fe5cd3a72b3c3e59eb880808efc2df442R876.

Local testing confirms that the build is much slower after this commit than before.

Metadata

Metadata

Assignees

Labels

Domain: PerformanceReports of unusually slow behaviorFixedA PR has been merged for this issueNeeds InvestigationThis issue needs a team member to investigate its status.

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions