Skip to content

Add env var to disable SIMD in setup.py#231

Merged
zfergus merged 3 commits into
mainfrom
python/optional-simd
May 1, 2026
Merged

Add env var to disable SIMD in setup.py#231
zfergus merged 3 commits into
mainfrom
python/optional-simd

Conversation

@zfergus
Copy link
Copy Markdown
Member

@zfergus zfergus commented May 1, 2026

Description

  • Add IPCTK_WITH_SIMD environment variable to control SIMD support in Python builds
  • Reformat setup.py to match standard Python style guidelines

Type of change

  • Bug fix (non-breaking change which fixes an issue)

- Add `IPCTK_WITH_SIMD` environment variable to control SIMD support in
  Python builds
- Reformat `setup.py` to match standard Python style guidelines
@zfergus zfergus marked this pull request as ready for review May 1, 2026 15:11
Copilot AI review requested due to automatic review settings May 1, 2026 15:11
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a build-time switch to disable SIMD in the Python packaging flow (to avoid platform-specific build failures) and updates formatting in the Python build script.

Changes:

  • Add IPCTK_WITH_SIMD environment variable support in setup.py and forward it to CMake as -DIPC_TOOLKIT_WITH_SIMD=....
  • Disable SIMD in the GitHub Actions Python workflow by setting IPCTK_WITH_SIMD=0 during pip install.
  • Reformat portions of setup.py for readability/consistency.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
setup.py Adds env-var-controlled SIMD toggle passed through to CMake; includes formatting adjustments.
.github/workflows/python.yml Forces SIMD off in CI during Python package build/install step.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread setup.py Outdated
Comment thread .github/workflows/python.yml
zfergus added 2 commits May 1, 2026 11:17
- Support "off", "false", and "no" values for IPCTK_WITH_SIMD in
  setup.py
- Re-enable SIMD for macOS and Windows Python CI builds
- Document the `IPCTK_WITH_SIMD` environment variable for `pip install`
- List accepted falsy values for disabling SIMD optimizations
- Add a note on forcing a source build from PyPI to apply the flag
@zfergus zfergus merged commit e400bb0 into main May 1, 2026
5 checks passed
@zfergus zfergus deleted the python/optional-simd branch May 1, 2026 15:25
@zfergus zfergus added this to the v1.6.0 milestone May 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants