发布

  • build: add -O3 optimization to CGO flags (#13877)

    frostbyte_neo 发布于 2026-01-24 18:55:38 +00:00

    CGO_CFLAGS and CGO_CXXFLAGS were being set without optimization flags,
    which overrides Go's default -O2 and results in unoptimized C++ code.

    This caused significant performance degradation in release builds
    compared to local go build which uses the default optimization.

    • build_darwin.sh: add -O3 to CGO_CFLAGS and CGO_CXXFLAGS exports
    • Dockerfile: preserve CGO_CFLAGS/CGO_CXXFLAGS from build args instead
      of overwriting them
    • app/README.md: update documentation to include -O3
    下载附件