Skip to content

Why is machine loading rounded? #484

@expipiplus1

Description

@expipiplus1

https://github.com/NixOS/hydra/blob/master/src/hydra-queue-runner/dispatcher.cc#L131-L132

In the comparison for machine selection:

float ta = std::round(a.currentJobs / a.machine->speedFactor);
float tb = std::round(b.currentJobs / b.machine->speedFactor);

This doesn't seem necessary, and leads to incorrect results when the machines have a high speedFactor.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions