Skip to content

Consider necessity of libfmt dependency #2334

@mazunki

Description

@mazunki

From #2309:

Approving this conditionally: I want us to make 100% sure that we can't convince std::fmt to work for us, without having to add futex. If we do need futex, please post an issue to remove this dependency if / when we get to implementing or stubbing futex.

Early printing of kprintf() currently has a fixed size allocation, meaning we could potentially get rid of libfmt as a dependency. The change itself would be close to trivial. That said, #2309 (comment) showcases how libfmt allows us to do this conversion at compile-time with dynamically sized strings. This might be useful if we want to remove the fixed size from the kernel's serial console, or for other things relying on a futex before it's ready.

On top of this, libfmt facilitates adding colours and similar things to strings. We should look into whether C++ lets us do that sort of thing in a standard way.

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