siboehm / lleaves

Compiler for LightGBM gradient-boosted trees, based on LLVM. Speeds up prediction by ≥10x.
https://lleaves.readthedocs.io/en/latest/
MIT License
343 stars 29 forks source link

Specify instruction set #12

Open jtilly opened 2 years ago

jtilly commented 2 years ago

It would be great if we could specify the instruction set when compiling and not necessarily compile for march=native.

siboehm commented 2 years ago

I think an march parameter added to Model.compile() would make sense:

Default would still be march=native.

siboehm commented 2 years ago

Note to self: I seems like the llvmlite pip packages only ship the backends required for the local arch, hence there's no way to set-up lleaves as a proper cross-compiler.