[all-commits] [llvm/llvm-project] 1d40c4: [clang-tools-extra] fix the check for if '-latomic...

Gokturk Yuksek via All-commits all-commits at lists.llvm.org
Fri Feb 14 06:16:42 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 1d40c4150630729a9c1ce5119a8027dac93a5b2d
      https://github.com/llvm/llvm-project/commit/1d40c4150630729a9c1ce5119a8027dac93a5b2d
  Author: Gokturk Yuksek <gokturk at binghamton.edu>
  Date:   2020-02-14 (Fri, 14 Feb 2020)

  Changed paths:
    M clang-tools-extra/clangd/CMakeLists.txt

  Log Message:
  -----------
  [clang-tools-extra] fix the check for if '-latomic' is necessary

Summary:
The CheckAtomic module performs two tests to determine if passing
'-latomic' to the linker is required: one for 64-bit atomics, and
another for non-64-bit atomics. clangd only uses the result from
HAVE_CXX_ATOMICS64_WITHOUT_LIB. This is incomplete because there are
uses of non-64-bit atomics in the code, such as the ReplyOnce::Replied
of type std::atomic<bool> defined in clangd/ClangdLSPServer.cpp.

Fix by also checking for the result of HAVE_CXX_ATOMICS_WITHOUT_LIB.

See also: https://reviews.llvm.org/D68964

Reviewers: ilya-biryukov, nridge, kadircet, beanz, compnerd, luismarques
Reviewed By: luismarques
Tags: #clang
Differential Revision: https://reviews.llvm.org/D69869




More information about the All-commits mailing list