[all-commits] [llvm/llvm-project] 43bfde: [OpenMP] Initialize td_last_tied when an untied ta...
Carlos Seo via All-commits
all-commits at lists.llvm.org
Fri Oct 2 07:33:23 PDT 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 43bfdeef96d07dba07eae2285e7eba1f2afbacb3
https://github.com/llvm/llvm-project/commit/43bfdeef96d07dba07eae2285e7eba1f2afbacb3
Author: Carlos Seo <carlos.seo at linaro.org>
Date: 2026-10-02 (Fri, 02 Oct 2026)
Changed paths:
Log Message:
-----------
[OpenMP] Initialize td_last_tied when an untied task starts (#214320)
An untied task inherits td_last_tied -- the innermost tied task the
thread is bound to -- from the task it suspends. That inheritance only
happened in __kmp_invoke_task(), so any path that made an untied task
the thread's current task without going through it left td_last_tied at
the NULL that __kmp_task_alloc() assigns. This causes a crash when
__kmp_task_is_allowed() dereferences NULL.
Move the inheritance into __kmp_task_start(), before it sets
th_current_task. Besides the if0 path, this also covers a cancelled
untied task, which is never invoked but still releases its dependences
while it is the current task, and the pattern task of an untied
taskloop, which the runtime starts and finishes directly.
Fixes #172938
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list