Skip to content

Massive CPU usage on exec() windows #108

@Bartvds

Description

@Bartvds

A project I work on used ShellJS to run a node.js based JS compiler, but it was slow and had massive CPU usage on Windows.

While researching it found this comment: https://github.com/arturadib/shelljs/blob/master/src/exec.js#L66-L68

We swapped ShellJS for a child_process.spawn() and so far it looks like we gained ~20% overall speed with a lot less CPU use.

No idea what is going on in that sync-hack but it is not a good solution, at least not on Windows.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions