]> git.ipfire.org Git - thirdparty/postgresql.git/commit
jit: Don't inline functions that access thread-locals.
authorThomas Munro <tmunro@postgresql.org>
Thu, 22 Jul 2021 02:11:17 +0000 (14:11 +1200)
committerThomas Munro <tmunro@postgresql.org>
Thu, 22 Jul 2021 03:06:04 +0000 (15:06 +1200)
commite515943acc06a37ef4e8f9a723504c5102e87eed
tree48fdb2983e32a199d904b93a874ff7907102b598
parent7155e0522fbf1403711ce712f48d346c0c85c179
jit: Don't inline functions that access thread-locals.

Code inlined by LLVM can crash or fail with "Relocation type not
implemented yet!" if it tries to access thread local variables.  Don't
inline such code.

Back-patch to 11, where LLVM arrived.  Bug #16696.

Author: Dmitry Marakasov <amdmi3@amdmi3.ru>
Reviewed-by: Andres Freund <andres@anarazel.de>
Discussion: https://postgr.es/m/16696-29d944a33801fbfe@postgresql.org
src/backend/jit/llvm/llvmjit_inline.cpp