Skip to content

Linux X11: Slow window creation #751

@kimsnj

Description

@kimsnj

I am experiencing a very slow window creation on a linux laptop.
I used following snippet to test it:

extern crate winit;

fn main() {
    let events_loop = winit::EventsLoop::new();

    let _window = winit::WindowBuilder::new()
        .with_title("A fantastic window!")
        .build(&events_loop)
        .unwrap();
}

And as a result of time:

> time target/release/examples/open

real	0m2.269s
user	0m0.005s
sys	0m0.005s

My laptop is running Ubuntu Gnome 16.04 with X11.
It has an Intel i7-4810MQ and is using the integrated GPU.

I created a flamegraph here (doesn't seem to be possible to include directly the svg as attachement).

Any clue on where the issue might come from / how to dig deeper ?
Thanks in advance for your help.

Metadata

Metadata

Assignees

No one assigned

    Labels

    C - needs investigationIssue must be confirmed and researchedDS - x11Affects the X11 backend, or generally free Unix platforms

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions