🌐 AI搜索 & 代理 主页
Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 52 additions & 27 deletions meson.options
Original file line number Diff line number Diff line change
@@ -1,45 +1,70 @@
# BLAS / LAPACK Selection
option('blas', type: 'string', value: 'auto',
description: 'Option for BLAS library selection. By default, try to find any in the order given by `blas-order`')
description: 'BLAS library to use (default: autodetect based on blas-order)')
option('lapack', type: 'string', value: 'auto',
description: 'Option for LAPACK library selection. By default, try to find any in the order given by `lapack-order`')
option('allow-noblas', type: 'boolean', value: true,
description: 'If set to true, allow building with (slow!) internal fallback routines')
description: 'LAPACK library to use (default: autodetect based on lapack-order)')

option('blas-order', type: 'array', value: ['auto'],
description: 'Order of BLAS libraries to search for. E.g.: mkl,openblas,blis,blas')
description: 'Preferred search order for BLAS libraries (e.g., mkl, openblas, blis, blas)')
option('lapack-order', type: 'array', value: ['auto'],
description: 'Order of LAPACK libraries to search for. E.g.: mkl,openblas,lapack')
description: 'Preferred search order for LAPACK libraries (e.g., mkl, openblas, lapack)')

option('allow-noblas', type: 'boolean', value: true,
Copy link
Member

Choose a reason for hiding this comment

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

This goes together with the blas/lapack options, it's better in its original place - please put it back there.

description: 'Allow fallback slow internal BLAS implementation if no library is found')

option('use-ilp64', type: 'boolean', value: false,
description: 'Use ILP64 (64-bit integer) BLAS and LAPACK interfaces')
description: 'Use ILP64 (64-bit integer) BLAS/LAPACK interfaces')

option('blas-symbol-suffix', type: 'string', value: 'auto',
description: 'BLAS and LAPACK symbol suffix to use, if any')
description: 'Symbol suffix for BLAS/LAPACK symbols (if any)')


# MKL / Library Behavior
Copy link
Member

Choose a reason for hiding this comment

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

This is only a single option so doesn't seem to deserve a separate header; it's part of the BLAS options.

option('mkl-threading', type: 'string', value: 'auto',
description: 'MKL threading method, one of: `seq`, `iomp`, `gomp`, `tbb`')
choices: ['auto', 'seq', 'iomp', 'gomp', 'tbb'],
description: 'Threading backend for MKL')

option('disable-svml', type: 'boolean', value: false,
Copy link
Member

Choose a reason for hiding this comment

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

These three options should be part of the SIMD options sections

description: 'Disable building against SVML')
description: 'Disable use of Intel SVML')
option('disable-highway', type: 'boolean', value: false,
description: 'Disables SIMD-optimized operations related to Google Highway')
description: 'Disable SIMD ops based on Google Highway')
option('disable-intel-sort', type: 'boolean', value: false,
description: 'Disables SIMD-optimized operations related to Intel x86-simd-sort')
description: 'Disable Intel x86-simd-sort optimized sort algorithms')


# Threading & Parallelism
option('disable-threading', type: 'boolean', value: false,
description: 'Disable threading support (see `NPY_ALLOW_THREADS` docs)')
description: 'Completely disable NumPy threading support')
Copy link
Member

Choose a reason for hiding this comment

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

The NPY_ALLOW_THREADS hint is useful, it guides the user to https://numpy.org/devdocs/reference/c-api/array.html#threading-support. Please restore its mention.


option('enable-openmp', type: 'boolean', value: false,
description: 'Enable building NumPy with openmp support')
description: 'Enable compilation with OpenMP support')


# CPU Optimization / SIMD
option('disable-optimization', type: 'boolean', value: false,
description: 'Disable CPU optimized code (dispatch,simd,unroll...)')
description: 'Disable all CPU optimizations (dispatch, SIMD, loop unrolling)')

option('cpu-baseline', type: 'string', value: 'min',
description: 'Minimal set of required CPU features')
description: 'Required baseline CPU features')

option('cpu-baseline-detect', type: 'feature', value: 'auto',
description: 'Detect CPU baseline from the compiler flags')
description: 'Detect CPU baseline from compiler flags automatically')

option('cpu-dispatch', type: 'string', value: 'max',
description: 'Dispatched set of additional CPU features')
description: 'Additional CPU features to dispatch to (beyond baseline)')


# SIMD Test Options
option('test-simd', type: 'array',
value: [
'BASELINE', 'X86_V2', 'X86_V3', 'X86_V4',
'VSX', 'VSX2', 'VSX3', 'VSX4',
'NEON', 'ASIMD',
'VX', 'VXE', 'VXE2',
'LSX',
],
description: 'Specify a list of CPU features to be tested against NumPy SIMD interface')
value: [
'BASELINE', 'X86_V2', 'X86_V3', 'X86_V4',
'VSX', 'VSX2', 'VSX3', 'VSX4',
'NEON', 'ASIMD',
'VX', 'VXE', 'VXE2',
'LSX',
],
description: 'CPU SIMD feature sets to be tested by the NumPy SIMD test module')

option('test-simd-args', type: 'string', value: '',
description: 'Extra args to be passed to the `_simd` module that is used for testing the NumPy SIMD interface')
description: 'Extra arguments passed to the internal _simd test module')