[all-commits] [llvm/llvm-project] 970105: Introduce @llvm.threadlocal.address intrinsic to a...

Chuanqi Xu via All-commits all-commits at lists.llvm.org
Sun Jul 31 19:53:18 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9701053517100045ca9fb0fd81233314ab08f600
      https://github.com/llvm/llvm-project/commit/9701053517100045ca9fb0fd81233314ab08f600
  Author: Chuanqi Xu <yedeng.yd at linux.alibaba.com>
  Date:   2022-08-01 (Mon, 01 Aug 2022)

  Changed paths:
    M llvm/docs/LangRef.rst
    M llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
    M llvm/include/llvm/IR/IRBuilder.h
    M llvm/include/llvm/IR/Intrinsics.td
    M llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
    M llvm/lib/IR/IRBuilder.cpp
    A llvm/test/CodeGen/X86/threadlocal_address.ll

  Log Message:
  -----------
  Introduce @llvm.threadlocal.address intrinsic to access TLS variable

This belongs to a series of patches which try to solve the thread
identification problem in coroutines. See
https://discourse.llvm.org/t/address-thread-identification-problems-with-coroutine/62015
for a full background.

The problem consists of two concrete problems: TLS variable and readnone
functions. This patch tries to convert the TLS problem to readnone
problem by converting the access of TLS variable to an intrinsic which
is marked as readnone.

The readnone problem would be addressed in following patches.

Reviewed By: nikic, jyknight, nhaehnle, ychen

Differential Revision: https://reviews.llvm.org/D125291




More information about the All-commits mailing list