llama.cpp
Avoid -march=native when reproducible build is wanted
#11366
Merged

Avoid -march=native when reproducible build is wanted #11366

ggerganov merged 1 commit into ggml-org:master from bmwiedemann:native
bmwiedemann
bmwiedemann115 days ago (edited 115 days ago)

See https://reproducible-builds.org/ for why this is good.

Without this patch, compiling on different machines produced different binaries, which made verification of results difficult.

Fixes: #11317

This PR was done while working on reproducible builds for openSUSE.

github-actions github-actions added ggml
ggerganov
ggerganov approved these changes on 2025-01-24
ggerganov114 days ago

I suppose this env variable is specific only for this particular use case and it won't clash with some other workflow?

Maybe add a message(STATUS ...) to be more verbose when GGML_NATIVE_DEFAULT is set to OFF.

bmwiedemann Avoid -march=native when reproducible build is wanted
9a391b98
bmwiedemann bmwiedemann force pushed from 06f03f50 to 9a391b98 114 days ago
bmwiedemann
bmwiedemann114 days ago

The variable is defined in https://reproducible-builds.org/specs/source-date-epoch/ - multiple distributions (Debian, Arch, openSUSE) set it during build to achieve reproducible builds results.

I pushed an update with message(STATUS...)

ggerganov ggerganov merged 1af6945e into master 114 days ago
bmwiedemann bmwiedemann deleted the native branch 114 days ago

Login to write a write a comment.

Login via GitHub

Reviewers
Assignees
No one assigned
Labels
Milestone