File tree Expand file tree Collapse file tree 5 files changed +6
-30
lines changed Expand file tree Collapse file tree 5 files changed +6
-30
lines changed Original file line number Diff line number Diff line change 77
77
~/.cargo/registry/cache/
78
78
~/.cargo/git/db/
79
79
key : ${{ github.job }}-${{ hashFiles('./Cargo.lock') }}-${{ matrix.version }}
80
- - name : Set up Clang-16
81
- run : |
82
- sudo sh -c 'echo "deb http://apt.llvm.org/$(lsb_release -cs)/ llvm-toolchain-$(lsb_release -cs)-16 main" >> /etc/apt/sources.list'
83
- wget --quiet -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
84
- sudo apt-get update
85
- sudo apt-get install -y clang-16
86
- sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-16 128
87
80
- name : Build
88
81
run : |
89
82
export PGRX_PG_CONFIG_PATH=$(pwd)/vendor/pg${VERSION}_${ARCH}_debian/pg_config/pg_config
Original file line number Diff line number Diff line change 59
59
sudo apt-get update
60
60
sudo apt-get install -y build-essential crossbuild-essential-arm64
61
61
sudo apt-get install -y qemu-user-static
62
- echo 'target.aarch64-unknown-linux-gnu.linker = "aarch64-linux-gnu-gcc"' | tee ~/.cargo/config.toml
62
+ touch ~/.cargo/config.toml
63
+ echo 'target.aarch64-unknown-linux-gnu.linker = "aarch64-linux-gnu-gcc"' >> ~/.cargo/config.toml
64
+ echo 'target.aarch64-unknown-linux-gnu.runner = ["qemu-aarch64-static", "-L", "/usr/aarch64-linux-gnu"]' >> ~/.cargo/config.toml
65
+ rustup target add x86_64-unknown-linux-gnu
66
+ rustup target add aarch64-unknown-linux-gnu
63
67
- name : Set up Sccache
64
68
uses :
mozilla-actions/[email protected]
65
69
- name : Set up Cache
71
75
~/.cargo/registry/cache/
72
76
~/.cargo/git/db/
73
77
key : ${{ github.job }}-${{ hashFiles('./Cargo.lock') }}-${{ matrix.version }}-${{ matrix.arch }}
74
- - name : Set up Clang-16
75
- run : |
76
- sudo sh -c 'echo "deb http://apt.llvm.org/$(lsb_release -cs)/ llvm-toolchain-$(lsb_release -cs)-16 main" >> /etc/apt/sources.list'
77
- wget --quiet -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
78
- sudo apt-get update
79
- sudo apt-get install -y clang-16
80
- sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-16 128
81
78
- name : Build
82
79
run : |
83
80
export PGRX_PG_CONFIG_PATH=$(pwd)/vendor/pg${VERSION}_${ARCH}_debian/pg_config/pg_config
Original file line number Diff line number Diff line change 73
73
~/.cargo/registry/cache/
74
74
~/.cargo/git/db/
75
75
key : ${{ github.job }}-${{ hashFiles('./Cargo.lock') }}-${{ matrix.version }}-${{ matrix.arch }}
76
- - name : Set up Clang-16
77
- run : |
78
- sudo sh -c 'echo "deb http://apt.llvm.org/$(lsb_release -cs)/ llvm-toolchain-$(lsb_release -cs)-16 main" >> /etc/apt/sources.list'
79
- wget --quiet -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
80
- sudo apt-get update
81
- sudo apt-get install -y clang-16
82
- sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-16 128
83
76
- name : Schema
84
77
run : |
85
78
echo -n $PGVECTORS_SCHEMA > .schema
Original file line number Diff line number Diff line change 78
78
~/.cargo/registry/cache/
79
79
~/.cargo/git/db/
80
80
key : ${{ github.job }}-${{ hashFiles('./Cargo.lock') }}-${{ matrix.arch }}
81
- - name : Set up Clang-16
82
- run : |
83
- sudo sh -c 'echo "deb http://apt.llvm.org/$(lsb_release -cs)/ llvm-toolchain-$(lsb_release -cs)-16 main" >> /etc/apt/sources.list'
84
- wget --quiet -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
85
- sudo apt-get update
86
- sudo apt-get install -y clang-16
87
- sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-16 128
88
81
- name : Clippy
89
82
run : |
90
83
cargo clippy --workspace --exclude pgvectors --exclude pyvectors --target $ARCH-unknown-linux-gnu
Original file line number Diff line number Diff line change @@ -96,7 +96,7 @@ mod mul_add_round {
96
96
// this hint is used to disable loop unrolling
97
97
while std:: hint:: black_box ( n) > 0 {
98
98
let x = a. read ( ) ;
99
- let v = ( k * x + b) . round_ties_even ( ) as u8 ;
99
+ let v = x . mul_add ( k , b) . round_ties_even ( ) as u8 ;
100
100
r. write ( v) ;
101
101
n -= 1 ;
102
102
a = a. add ( 1 ) ;
You can’t perform that action at this time.
0 commit comments