# FYI llvm-17 update PR is live

**URL:** https://numba.discourse.group/t/fyi-llvm-17-update-pr-is-live/2538
**Category:** llvmlite
**Created:** [April 24, 2024, 5:56pm UTC](https://numba.discourse.group/t/fyi-llvm-17-update-pr-is-live/2538 "2024-04-24T17:56:21Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![modiking](https://yyz2.discourse-cdn.com/free1/user_avatar/numba.discourse.group/modiking/32/1009_2.png) [@modiking](https://numba.discourse.group/u/modiking)
#### Post date: [April 24, 2024, 5:56pm UTC](https://numba.discourse.group/t/fyi-llvm-17-update-pr-is-live/2538/1 "2024-04-24T17:56:21Z")

</div>

> <https://github.com/numba/llvmlite/pull/1042>
>
> \`\`\`
> ~/llvm-project# git log
> commit 6009708b4367171ccdbf4b5905cb6a803753fe18 (H…EAD -\> release/17.x, tag: llvmorg-17.0.6, upstream/release/17.x)
> ~/llvm-project/build-rel-static# cmake \\
> -G Ninja \\
> -DCMAKE\_CXX\_COMPILER=clang++ \\
> -DCMAKE\_C\_COMPILER=clang \\
> -DCMAKE\_ASM\_COMPILER=clang \\
> -DCMAKE\_ASM\_COMPILER\_ID=Clang \\
> -DLLVM\_TARGETS\_TO\_BUILD="X86" \\
> -DLLVM\_ENABLE\_LLD=ON\\
> -DLLVM\_ENABLE\_PROJECTS="clang;lld" \\
> -DCMAKE\_BUILD\_TYPE=RelWithDebInfo \\
> -DCMAKE\_EXPORT\_COMPILE\_COMMANDS=1 \\
> -DCMAKE\_INSTALL\_PREFIX=$1 \\
> -DBUILD\_SHARED\_LIBS=false \\
> -DLLVM\_ENABLE\_ASSERTIONS=ON \\
> -DLLVM\_OPTIMIZED\_TABLEGEN=true \\
> ../llvm
> ~/llvm-project/build-rel-static# ninja
> ...
> ~/migration/llvmlite# git log
> commit 4907a4eee128ae5d95eddbd0ce4aeaa83bab4787 (HEAD -\> modiking/llvm17, origin/modiking/llvm17)
> ~/migration/llvmlite# LLVM\_CONFIG=/home/modimo/llvm-project/build-rel-static/bin/llvm-config python3.9 setup.py build
> ~/migration/llvmlite# LD\_LIBRARY\_PATH=/home/modimo/llvm-project/build-rel-static/lib python3.9 runtests.py 
> ..s................................................................s.............................................................x.sss...........s.....................................................................................................................................................................................................................................
> \----------------------------------------------------------------------
> Ran 375 tests in 9.153s
> 
> OK (skipped=6, expected failures=1)
> \`\`\`
> 
> TODO:
> 1. I haven't hooked up all the boilerplate for every pass. With New Pass Manager (NPM) certain passes become specific to Module/Function/Loop and need adaptors to pass to the FunctionPassManager/ModulePassManager
> 2. I haven't tested with SVML patches in LLVM nor with SVML in general. I don't expect too much work beyond rebasing the LLVM patch however. Would appreciate any guidance on how to do this
> 3. Currently I don't have a conda package for LLVM. Would appreciate any help on getting that set up
> 
> High-level details:
> 1. The llvm-c APIs have not been updated from NPM. AFAICT the "c" APIs are ad-hoc maintained by whoever uses them. We can definitely bring up that boilerplate but currently the setup is using the C++ APIs
> 2. NPM has additional state for analysis managers it needs to carry. It also \*\*must\*\* be initialized by the pass builder before using. I've kept the high level python APIs as close as before but we can certainly re-evaluate how we want to expose these to keep things simpler
> 3. Opaque pointers means types can no longer be queried on pointers. Instead I've updated the general type query to use \`global\_value\_type\` which looks at the value rather than the pointer

Open to feedback here or in the PR itself 🙂

---

<div class="post-metadata">

### Author: ![modiking](https://yyz2.discourse-cdn.com/free1/user_avatar/numba.discourse.group/modiking/32/1009_2.png) [@modiking](https://numba.discourse.group/u/modiking)
#### Post date: [April 24, 2024, 5:59pm UTC](https://numba.discourse.group/t/fyi-llvm-17-update-pr-is-live/2538/2 "2024-04-24T17:59:54Z")

</div>

Looks like I can’t add reviewers, if someone wouldn’t mind editing the PR lol
