Skip to content

Commit d709c87

Browse files
committed
Merge branch 'hipo-ci' into readme-links
2 parents 082c9aa + 994f18d commit d709c87

3 files changed

Lines changed: 49 additions & 20 deletions

File tree

.github/workflows/hipo-fetch.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,8 @@ jobs:
115115
-DCMAKE_CXX_COMPILER=g++ \
116116
-DCMAKE_C_FLAGS="-m32" \
117117
-DCMAKE_CXX_FLAGS="-m32" \
118-
-DCMAKE_SHARED_LINKER_FLAGS="-m32"
118+
-DCMAKE_SHARED_LINKER_FLAGS="-m32" \
119+
-DALL_TESTS=${{ matrix.all_tests }}
119120
120121
- name: Build
121122
working-directory: ${{runner.workspace}}/build
@@ -207,7 +208,8 @@ jobs:
207208
run: |
208209
export CC=arm-linux-gnueabihf-gcc
209210
export CXX=arm-linux-gnueabihf-g++
210-
cmake $GITHUB_WORKSPACE
211+
cmake $GITHUB_WORKSPACE \
212+
-DALL_TESTS=${{ matrix.all_tests }}
211213
212214
- name: Build
213215
working-directory: ${{runner.workspace}}/build

check/CMakeLists.txt

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -286,9 +286,16 @@ if ((NOT FAST_BUILD OR ALL_TESTS) AND NOT (BUILD_EXTRA_UNIT_ONLY))
286286
# "--parallel=on"
287287
)
288288

289+
if(CMAKE_SIZEOF_VOID_P EQUAL 4) OR if(CMAKE_C_FLAGS MATCHES "-m32" OR CMAKE_CXX_FLAGS MATCHES "-m32")
290+
set(IS_32 ON)
291+
else()
292+
set(IS_32 OFF)
293+
endif()
294+
289295
if (UNIX AND NOT APPLE AND
290296
NOT CMAKE_CXX_COMPILER_ID STREQUAL "IntelLLVM"
291-
AND CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|amd64")
297+
AND CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|amd64"
298+
AND NOT IS_32)
292299
if (CUPDLP_GPU)
293300
set(pdlpInstances
294301
"25fv47\; 5.501847\;"
@@ -442,7 +449,7 @@ if ((NOT FAST_BUILD OR ALL_TESTS) AND NOT (BUILD_EXTRA_UNIT_ONLY))
442449
add_instancetests(successRiscVInstances "Optimal")
443450
endif()
444451
elseif(NOT (CMAKE_SYSTEM_PROCESSOR MATCHES "arm|aarch64") AND
445-
NOT (CMAKE_SIZEOF_VOID_P EQUAL 4))
452+
NOT IS_32)
446453
add_instancetests(successInstances "Optimal")
447454
endif()
448455

docs/src/installation.md

Lines changed: 36 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -7,43 +7,63 @@ HiGHS uses CMake as build system, and requires at least version
77

88
## HiGHS with HiPO
99

10-
HiGHS does not have any external dependencies, however, the new interior point solver HiPO uses BLAS. At the moment HiPO is optional and can be enabled via CMake. To build HiPO, you need to have BLAS installed on your machine. Please follow the instructions below.
10+
HiGHS does not have any external dependencies, however, the new interior point solver HiPO uses BLAS. At the moment HiPO is optional and can be enabled via CMake.
1111

12-
#### BLAS
12+
### External ordering heuristics
1313

14-
On Linux, libblas and libopenblas are supported. We recomment libopenblas for its better performance, and it is found by default if available on the system. Install with
14+
HiPO also relies on a fill-reducing ordering heuristic. HiGHS includes the source code of Metis, AMD and RCM, three open-source ordering heuristics. Their source code is already part of the HiGHS library, so there is no need to link them. In particular, there is no need to have Metis installed separately, as in previous versions of HiPO. These source codes can be found in extern/metis, extern/amd, extern/rcm, together with the respective license files. Notice that the HiGHS source code is MIT licensed. However, if you build HiGHS with HiPO support, then libhighs and the HiGHS executables are licensed Apache 2.0, due to the presence of Metis and AMD.
1515

16-
```
17-
sudo apt update
18-
sudo apt install libopenblas-dev
19-
```
16+
### BLAS
2017

2118
On MacOS no BLAS installation is required because HiPO uses [Apple Accelerate](https://developer.apple.com/accelerate/) by default.
2219

23-
On Windows, OpenBLAS is required. It could be installed via [vcpkg](https://learn.microsoft.com/en-us/vcpkg/get_started/overview) with
20+
On Windows and Linux, you can either compile OpenBLAS at configure time using the option `-DBUILD_OPENBLAS=ON` (`OFF` by default) or compile BLAS using the instructions below.
21+
22+
#### MacOS
2423

24+
To build HiPO on MacOS, run
2525
```
26-
vcpkg install openblas[threads]
26+
cmake -S. -B build -DHIPO=ON
2727
```
28-
Note, that `[threads]` is required for HiPO.
2928

30-
To specify explicitly which BLAS vendor to look for, `BLA_VENDOR` coud be set in CMake, e.g. `-DBLA_VENDOR=Apple` or `-DBLA_VENDOR=OpenBLAS`. Alternatively, to specify which BLAS library to use, set `BLAS_LIBRARIES` to the full path of the library e.g. `-DBLAS_LIBRARIES=/path_to/libopenblas.so`.
29+
#### Linux and Windows: Compile OpenBLAS at configure time
3130

32-
#### External ordering heuristics
31+
```
32+
cmake -S. -B build -DHIPO=ON -DBUILD_OPENBLAS=ON
33+
```
3334

34-
HiPO also relies on a fill-reducing ordering heuristic. HiGHS includes the source code of Metis, AMD and RCM, three open-source ordering heuristics. Their source code is already part of the HiGHS library, so there is no need to link them. In particular, there is no need to have Metis installed separately, as in previous versions of HiPO. These source codes can be found in extern/metis, extern/amd, extern/rcm, together with the respective license files. Notice that the HiGHS source code is MIT licensed. However, if you build HiGHS with HiPO support, then libhighs and the HiGHS executables are licensed Apache 2.0, due to the presence of Metis and AMD.
35+
#### Linux and Windows: Link with BLAS installatied on your machine
3536

36-
### HiPO
37+
On Linux, libblas and libopenblas are supported. We recommend libopenblas for its better performance, and it is found by default if available on the system. Install with
38+
39+
```
40+
sudo apt update
41+
sudo apt install libopenblas-dev
42+
```
3743

38-
To install HiPO, on Linux and MacOS, run
44+
To build HiPO, run
3945
```
4046
cmake -S. -B build -DHIPO=ON
4147
```
48+
49+
On Windows, OpenBLAS is required. It could be installed via [vcpkg](https://learn.microsoft.com/en-us/vcpkg/get_started/overview) with
50+
51+
```
52+
vcpkg install openblas[threads]
53+
```
54+
55+
Note, that `[threads]` is required for HiPO.
56+
4257
On Windows, you also need to specify the path to OpenBLAS. If it was installed with vcpkg as suggested above, add the path to `vcpkg.cmake` to the CMake flags, e.g.
4358
```
44-
-DCMAKE_TOOLCHAIN_FILE="C:/vcpkg/scripts/buildsystems/vcpkg.cmake"
59+
cmake -S. -B build -DHIPO=ON -DCMAKE_TOOLCHAIN_FILE="C:/vcpkg/scripts/buildsystems/vcpkg.cmake"
4560
```
4661

62+
##### Path to BLAS
63+
64+
To specify explicitly which BLAS vendor to look for, `BLA_VENDOR` coud be set in CMake, e.g. `-DBLA_VENDOR=Apple` or `-DBLA_VENDOR=OpenBLAS`. Alternatively, to specify which BLAS library to use, set `BLAS_LIBRARIES` to the full path of the library e.g. `-DBLAS_LIBRARIES=/path_to/libopenblas.so`.
65+
66+
4767
## Bazel build
4868

4969
Alternatively, building with Bazel is supported for Bazel-based projects. To build HiGHS, from the root directory, run

0 commit comments

Comments
 (0)