• Giooschi@lemmy.world
    link
    fedilink
    English
    arrow-up
    3
    ·
    3 months ago

    Another option is to compile dependencies with LLVM and optimizations, which will likely be done only once in the first clean build, and then compile your main binary with Cranelift, thus getting the juicy fast compile times without having to worry about the slow dependencies.

    • BB_C@programming.dev
      link
      fedilink
      arrow-up
      1
      ·
      3 months ago

      Yes. And to complete the pro tips, the choice of linker can be very relevant. Using mold would come recommended nowadays.