Giter Club home page Giter Club logo

Comments (3)

fitzgen avatar fitzgen commented on May 26, 2024

Before we do any of this, we should have some #[bench]s so we can actually determine whether any given change is a win or not.

from rust-bindgen.

fitzgen avatar fitzgen commented on May 26, 2024

I think we should just uses the preprocessed stylo headers for benchmarking, eg https://gist.github.com/fitzgen/51962fef1a2cdb8fe874d94a5d22387a

We shouldn't try and assert that there is no diff between versions like our normal tests because its just way too big for diffs not to get introduced one way or another. Just a sanity test that it successfully builds + a bench timing how long it takes.

Depends on #584 first, so we can successfully process stylo headers again.

This would have the nice side benefit that stylo bindings would break because of bindgen master changes less often.

from rust-bindgen.

fitzgen avatar fitzgen commented on May 26, 2024

Ok, so I just went down a rabbit hole of trying to get rayon to run each of our analyses as its own fork-join task. The problem is that BindgenContext is not Sync because it has all these libclang FFI types in it (plus other things like Cell, but those are easy enough to stuff into a Mutex or whatever). Even BindgenOptions is not Sync for similar reasons. Also the syntex ExtCntxt thing is not Sync.

I tried splitting various non-Sync pieces of BindgenContext into a ParseContext and a CodegenContext depending on where they ended up used, but it is pretty hard to disentangle these bits.

Here is my WIP commit for posterity: fitzgen@5dbf850

I don't intend on continuing this work for the time being.

from rust-bindgen.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.