Skip to content

Commit f701768

Browse files
authored
[LLVM] Bump LLVM to 20.1.8 (#59225)
Notably this has the IRCE fix
1 parent dc78cd9 commit f701768

File tree

15 files changed

+531
-531
lines changed

15 files changed

+531
-531
lines changed

deps/checksums/clang

Lines changed: 120 additions & 120 deletions
Large diffs are not rendered by default.

deps/checksums/lld

Lines changed: 120 additions & 120 deletions
Large diffs are not rendered by default.

deps/checksums/llvm

Lines changed: 242 additions & 242 deletions
Large diffs are not rendered by default.

deps/clang.version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@
33
## jll artifact
44
# Clang (paired with LLVM, only here as a JLL download)
55
CLANG_JLL_NAME := Clang
6-
CLANG_JLL_VER := 20.1.2+0
6+
CLANG_JLL_VER := 20.1.8+0

deps/lld.version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22

33
## jll artifact
44
LLD_JLL_NAME := LLD
5-
LLD_JLL_VER := 20.1.2+0
5+
LLD_JLL_VER := 20.1.8+0

deps/llvm-tools.version

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@
33
## jll artifact
44
# LLVM_tools (downloads LLVM_jll to get things like `lit` and `opt`)
55
LLVM_TOOLS_JLL_NAME := LLVM
6-
LLVM_TOOLS_JLL_VER := 20.1.2+0
7-
LLVM_TOOLS_ASSERT_JLL_VER := 20.1.2+0
6+
LLVM_TOOLS_JLL_VER := 20.1.8+0
7+
LLVM_TOOLS_ASSERT_JLL_VER := 20.1.8+0

deps/llvm.version

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@
22

33
## jll artifact
44
LLVM_JLL_NAME := libLLVM
5-
LLVM_ASSERT_JLL_VER := 20.1.2+1
5+
LLVM_ASSERT_JLL_VER := 20.1.8+0
66
## source build
77
# Version number of LLVM
8-
LLVM_VER := 20.1.2
8+
LLVM_VER := 20.1.8
99
# Git branch name in `LLVM_GIT_URL` repository
10-
LLVM_BRANCH=julia-20.1.2-0
10+
LLVM_BRANCH=julia-20.1.8-0
1111
# Git ref in `LLVM_GIT_URL` repository
12-
LLVM_SHA1=julia-20.1.2-0
12+
LLVM_SHA1=julia-20.1.8-0
1313

1414
## Following options are used to automatically fetch patchset from Julia's fork. This is
1515
## useful if you want to build an external LLVM while still applying Julia's patches.
@@ -18,6 +18,6 @@ LLVM_APPLY_JULIA_PATCHES := 0
1818
# GitHub repository to use for fetching the Julia patches to apply to LLVM source code.
1919
LLVM_JULIA_DIFF_GITHUB_REPO := https://github.com/llvm/llvm-project
2020
# Base GitHub ref for generating the diff.
21-
LLVM_BASE_REF := llvm:llvmorg-20.1.2
21+
LLVM_BASE_REF := llvm:llvmorg-20.1.8
2222
# Julia fork's GitHub ref for generating the diff.
23-
LLVM_JULIA_REF := JuliaLang:julia-20.1.2-0
23+
LLVM_JULIA_REF := JuliaLang:julia-20.1.8-0

src/gc-stock.c

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ static void gc_sync_cache(jl_ptls_t ptls, jl_gc_mark_cache_t *gc_cache) JL_NOTSA
220220
}
221221

222222
// No other threads can be running marking at the same time
223-
static void gc_sync_all_caches(jl_ptls_t ptls)
223+
static void gc_sync_all_caches(jl_ptls_t ptls) JL_NOTSAFEPOINT
224224
{
225225
assert(gc_n_threads);
226226
for (int t_i = 0; t_i < gc_n_threads; t_i++) {
@@ -364,7 +364,7 @@ JL_DLLEXPORT jl_weakref_t *jl_gc_new_weakref_th(jl_ptls_t ptls, jl_value_t *valu
364364
return wr;
365365
}
366366

367-
static void clear_weak_refs(void)
367+
static void clear_weak_refs(void) JL_NOTSAFEPOINT
368368
{
369369
assert(gc_n_threads);
370370
for (int i = 0; i < gc_n_threads; i++) {
@@ -381,7 +381,7 @@ static void clear_weak_refs(void)
381381
}
382382
}
383383

384-
static void sweep_weak_refs(void)
384+
static void sweep_weak_refs(void) JL_NOTSAFEPOINT
385385
{
386386
assert(gc_n_threads);
387387
for (int i = 0; i < gc_n_threads; i++) {
@@ -1153,7 +1153,7 @@ static void gc_pool_sync_nfree(jl_gc_pagemeta_t *pg, jl_taggedvalue_t *last) JL_
11531153

11541154
// pre-scan pages to check whether there are enough pages so that's worth parallelizing
11551155
// also sweeps pages that don't need to be linearly scanned
1156-
int gc_sweep_prescan(jl_ptls_t ptls, jl_gc_padded_page_stack_t *new_gc_allocd_scratch)
1156+
int gc_sweep_prescan(jl_ptls_t ptls, jl_gc_padded_page_stack_t *new_gc_allocd_scratch) JL_NOTSAFEPOINT
11571157
{
11581158
// 4MB worth of pages is worth parallelizing
11591159
const int n_pages_worth_parallel_sweep = (int)(4 * (1 << 20) / GC_PAGE_SZ);
@@ -1210,7 +1210,7 @@ int gc_sweep_prescan(jl_ptls_t ptls, jl_gc_padded_page_stack_t *new_gc_allocd_sc
12101210
}
12111211

12121212
// wake up all threads to sweep the pages
1213-
void gc_sweep_wake_all_pages(jl_ptls_t ptls, jl_gc_padded_page_stack_t *new_gc_allocd_scratch)
1213+
void gc_sweep_wake_all_pages(jl_ptls_t ptls, jl_gc_padded_page_stack_t *new_gc_allocd_scratch) JL_NOTSAFEPOINT
12141214
{
12151215
int parallel_sweep_worthwhile = gc_sweep_prescan(ptls, new_gc_allocd_scratch);
12161216
if (parallel_sweep_worthwhile && !page_profile_enabled) {
@@ -1246,7 +1246,7 @@ void gc_sweep_wake_all_pages(jl_ptls_t ptls, jl_gc_padded_page_stack_t *new_gc_a
12461246
}
12471247

12481248
// wait for all threads to finish sweeping
1249-
void gc_sweep_wait_for_all_pages(void)
1249+
void gc_sweep_wait_for_all_pages(void) JL_NOTSAFEPOINT
12501250
{
12511251
jl_atomic_store(&gc_allocd_scratch, NULL);
12521252
while (jl_atomic_load_acquire(&gc_n_threads_sweeping_pools) != 0) {
@@ -1255,7 +1255,7 @@ void gc_sweep_wait_for_all_pages(void)
12551255
}
12561256

12571257
// sweep all pools
1258-
void gc_sweep_pool_parallel(jl_ptls_t ptls)
1258+
void gc_sweep_pool_parallel(jl_ptls_t ptls) JL_NOTSAFEPOINT
12591259
{
12601260
jl_atomic_fetch_add(&gc_n_threads_sweeping_pools, 1);
12611261
jl_gc_padded_page_stack_t *allocd_scratch = jl_atomic_load(&gc_allocd_scratch);
@@ -1306,7 +1306,7 @@ void gc_sweep_pool_parallel(jl_ptls_t ptls)
13061306
}
13071307

13081308
// free all pages (i.e. through `madvise` on Linux) that were lazily freed
1309-
void gc_free_pages(void)
1309+
void gc_free_pages(void) JL_NOTSAFEPOINT
13101310
{
13111311
size_t n_pages_seen = 0;
13121312
jl_gc_page_stack_t tmp;
@@ -1344,7 +1344,7 @@ void gc_free_pages(void)
13441344
}
13451345

13461346
// setup the data-structures for a sweep over all memory pools
1347-
static void gc_sweep_pool(void)
1347+
static void gc_sweep_pool(void) JL_NOTSAFEPOINT
13481348
{
13491349
gc_time_pool_start();
13501350

@@ -1466,7 +1466,7 @@ static void gc_sweep_pool(void)
14661466
gc_time_pool_end(current_sweep_full);
14671467
}
14681468

1469-
static void gc_sweep_perm_alloc(void)
1469+
static void gc_sweep_perm_alloc(void) JL_NOTSAFEPOINT
14701470
{
14711471
uint64_t t0 = jl_hrtime();
14721472
gc_sweep_sysimg();
@@ -2237,7 +2237,7 @@ JL_DLLEXPORT void jl_gc_mark_queue_objarray(jl_ptls_t ptls, jl_value_t *parent,
22372237

22382238
// Enqueue and mark all outgoing references from `new_obj` which have not been marked yet.
22392239
// `_new_obj` has its lowest bit tagged if it's in the remset (in which case we shouldn't update page metadata)
2240-
FORCE_INLINE void gc_mark_outrefs(jl_ptls_t ptls, jl_gc_markqueue_t *mq, void *_new_obj)
2240+
FORCE_INLINE void gc_mark_outrefs(jl_ptls_t ptls, jl_gc_markqueue_t *mq, void *_new_obj) JL_NOTSAFEPOINT
22412241
{
22422242
int meta_updated = (uintptr_t)_new_obj & GC_REMSET_PTR_TAG;
22432243
jl_value_t *new_obj = (jl_value_t *)((uintptr_t)_new_obj & ~(uintptr_t)GC_REMSET_PTR_TAG);
@@ -2513,7 +2513,7 @@ FORCE_INLINE void gc_mark_outrefs(jl_ptls_t ptls, jl_gc_markqueue_t *mq, void *_
25132513
}
25142514

25152515
// Used in gc-debug
2516-
void gc_mark_loop_serial_(jl_ptls_t ptls, jl_gc_markqueue_t *mq)
2516+
void gc_mark_loop_serial_(jl_ptls_t ptls, jl_gc_markqueue_t *mq) JL_NOTSAFEPOINT
25172517
{
25182518
while (1) {
25192519
void *new_obj = (void *)gc_ptr_queue_pop(&ptls->gc_tls.mark_queue);
@@ -2526,7 +2526,7 @@ void gc_mark_loop_serial_(jl_ptls_t ptls, jl_gc_markqueue_t *mq)
25262526
}
25272527

25282528
// Drain items from worker's own chunkqueue
2529-
void gc_drain_own_chunkqueue(jl_ptls_t ptls, jl_gc_markqueue_t *mq)
2529+
void gc_drain_own_chunkqueue(jl_ptls_t ptls, jl_gc_markqueue_t *mq) JL_NOTSAFEPOINT
25302530
{
25312531
jl_gc_chunk_t c = {.cid = GC_empty_chunk};
25322532
do {
@@ -2542,13 +2542,13 @@ void gc_drain_own_chunkqueue(jl_ptls_t ptls, jl_gc_markqueue_t *mq)
25422542
// is used to keep track of processed items. Maintaining this stack (instead of
25432543
// native one) avoids stack overflow when marking deep objects and
25442544
// makes it easier to implement parallel marking via work-stealing
2545-
JL_EXTENSION NOINLINE void gc_mark_loop_serial(jl_ptls_t ptls)
2545+
JL_EXTENSION NOINLINE void gc_mark_loop_serial(jl_ptls_t ptls) JL_NOTSAFEPOINT
25462546
{
25472547
gc_mark_loop_serial_(ptls, &ptls->gc_tls.mark_queue);
25482548
gc_drain_own_chunkqueue(ptls, &ptls->gc_tls.mark_queue);
25492549
}
25502550

2551-
void gc_mark_and_steal(jl_ptls_t ptls)
2551+
void gc_mark_and_steal(jl_ptls_t ptls) JL_NOTSAFEPOINT
25522552
{
25532553
int master_tid = jl_atomic_load(&gc_master_tid);
25542554
assert(master_tid != -1);
@@ -2670,7 +2670,7 @@ size_t gc_count_work_in_queue(jl_ptls_t ptls) JL_NOTSAFEPOINT
26702670
* the mark-loop after `gc_n_threads_marking` reaches zero.
26712671
*/
26722672

2673-
int gc_should_mark(void)
2673+
int gc_should_mark(void) JL_NOTSAFEPOINT
26742674
{
26752675
int should_mark = 0;
26762676
uv_mutex_lock(&gc_queue_observer_lock);
@@ -2703,14 +2703,14 @@ int gc_should_mark(void)
27032703
return should_mark;
27042704
}
27052705

2706-
void gc_wake_all_for_marking(jl_ptls_t ptls)
2706+
void gc_wake_all_for_marking(jl_ptls_t ptls) JL_NOTSAFEPOINT
27072707
{
27082708
uv_mutex_lock(&gc_threads_lock);
27092709
uv_cond_broadcast(&gc_threads_cond);
27102710
uv_mutex_unlock(&gc_threads_lock);
27112711
}
27122712

2713-
void gc_mark_loop_parallel(jl_ptls_t ptls, int master)
2713+
void gc_mark_loop_parallel(jl_ptls_t ptls, int master) JL_NOTSAFEPOINT
27142714
{
27152715
if (master) {
27162716
jl_atomic_store(&gc_master_tid, ptls->tid);
@@ -2729,7 +2729,7 @@ void gc_mark_loop_parallel(jl_ptls_t ptls, int master)
27292729
}
27302730
}
27312731

2732-
void gc_mark_loop(jl_ptls_t ptls)
2732+
void gc_mark_loop(jl_ptls_t ptls) JL_NOTSAFEPOINT
27332733
{
27342734
if (jl_n_markthreads == 0 || gc_heap_snapshot_enabled) {
27352735
gc_mark_loop_serial(ptls);
@@ -2739,13 +2739,13 @@ void gc_mark_loop(jl_ptls_t ptls)
27392739
}
27402740
}
27412741

2742-
void gc_mark_loop_barrier(void)
2742+
void gc_mark_loop_barrier(void) JL_NOTSAFEPOINT
27432743
{
27442744
assert(jl_atomic_load_relaxed(&gc_n_threads_marking) == 0);
27452745
jl_atomic_store_relaxed(&gc_master_tid, -1);
27462746
}
27472747

2748-
void gc_mark_clean_reclaim_sets(void)
2748+
void gc_mark_clean_reclaim_sets(void) JL_NOTSAFEPOINT
27492749
{
27502750
// Clean up `reclaim-sets`
27512751
for (int i = 0; i < gc_n_threads; i++) {
@@ -2888,7 +2888,7 @@ static void gc_mark_roots(jl_gc_markqueue_t *mq) JL_NOTSAFEPOINT
28882888

28892889
// find unmarked objects that need to be finalized from the finalizer list "list".
28902890
// this must happen last in the mark phase.
2891-
static void sweep_finalizer_list(arraylist_t *list)
2891+
static void sweep_finalizer_list(arraylist_t *list) JL_NOTSAFEPOINT
28922892
{
28932893
void **items = list->items;
28942894
size_t len = list->len;
@@ -2994,7 +2994,7 @@ JL_DLLEXPORT int64_t jl_gc_live_bytes(void)
29942994
return live_bytes;
29952995
}
29962996

2997-
uint64_t jl_gc_smooth(uint64_t old_val, uint64_t new_val, double factor)
2997+
uint64_t jl_gc_smooth(uint64_t old_val, uint64_t new_val, double factor) JL_NOTSAFEPOINT
29982998
{
29992999
double est = factor * old_val + (1 - factor) * new_val;
30003000
if (est <= 1)
@@ -3006,7 +3006,7 @@ uint64_t jl_gc_smooth(uint64_t old_val, uint64_t new_val, double factor)
30063006

30073007
// an overallocation curve inspired by array allocations
30083008
// grows very fast initially, then much slower at large heaps
3009-
static uint64_t overallocation(uint64_t old_val, uint64_t val, uint64_t max_val)
3009+
static uint64_t overallocation(uint64_t old_val, uint64_t val, uint64_t max_val) JL_NOTSAFEPOINT
30103010
{
30113011
// compute maxsize = maxsize + 4*maxsize^(7/8) + maxsize/8
30123012
// for small n, we grow much faster than O(n)
@@ -3990,7 +3990,7 @@ JL_DLLEXPORT int jl_gc_enable_conservative_gc_support(void)
39903990
}
39913991
}
39923992

3993-
JL_DLLEXPORT int jl_gc_conservative_gc_support_enabled(void)
3993+
JL_DLLEXPORT int jl_gc_conservative_gc_support_enabled(void) JL_NOTSAFEPOINT
39943994
{
39953995
return jl_atomic_load(&support_conservative_marking);
39963996
}

src/gc-stock.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -593,9 +593,9 @@ STATIC_INLINE void gc_time_count_mallocd_memory(int bits) JL_NOTSAFEPOINT
593593
#endif
594594

595595
#ifdef MEMFENCE
596-
void gc_verify_tags(void);
596+
void gc_verify_tags(void) JL_NOTSAFEPOINT;
597597
#else
598-
static inline void gc_verify_tags(void)
598+
static inline void gc_verify_tags(void) JL_NOTSAFEPOINT
599599
{
600600
}
601601
#endif
@@ -652,22 +652,22 @@ void jl_gc_debug_print(void);
652652
void gc_scrub_record_task(jl_task_t *ta) JL_NOTSAFEPOINT;
653653
void gc_scrub(void);
654654
#else
655-
static inline int jl_gc_debug_check_other(void)
655+
static inline int jl_gc_debug_check_other(void) JL_NOTSAFEPOINT
656656
{
657657
return 0;
658658
}
659-
static inline int gc_debug_check_pool(void)
659+
static inline int gc_debug_check_pool(void) JL_NOTSAFEPOINT
660660
{
661661
return 0;
662662
}
663-
static inline void jl_gc_debug_print(void)
663+
static inline void jl_gc_debug_print(void) JL_NOTSAFEPOINT
664664
{
665665
}
666666
static inline void gc_scrub_record_task(jl_task_t *ta) JL_NOTSAFEPOINT
667667
{
668668
(void)ta;
669669
}
670-
static inline void gc_scrub(void)
670+
static inline void gc_scrub(void) JL_NOTSAFEPOINT
671671
{
672672
}
673673
#endif

src/julia_gcext.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ JL_DLLEXPORT int jl_gc_enable_conservative_gc_support(void);
119119
// This function returns whether support for conservative scanning has
120120
// been enabled. The return values are the same as for
121121
// jl_gc_enable_conservative_gc_support().
122-
JL_DLLEXPORT int jl_gc_conservative_gc_support_enabled(void);
122+
JL_DLLEXPORT int jl_gc_conservative_gc_support_enabled(void) JL_NOTSAFEPOINT;
123123

124124
// Returns the base address of a memory block, assuming it is stored in
125125
// a julia memory pool. Return NULL otherwise. Conservative support

0 commit comments

Comments
 (0)