[clang-tools-extra] [clang-doc][NFC] clean unused variable in HTML generator (PR #135505)

2025-04-12 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/135505 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Pre-commit tests for static members and functions (PR #135456)

2025-04-11 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/135456 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libcxx] [libcxxabi] [libunwind] [llvm] [libcxxabi][libunwind] Support for using LLVM libc (PR #134893)

2025-04-08 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/134893 This generalizes the support added in #99287 renaming the option to RUNTIMES_USE_LIBC and integrating the module into libc++abi and libunwind as well. >From 1677ee5c547018472a1f6a29282d3af3500abcd7 Mon Sep 1

[clang] [clang] Fix UEFI Target info (PR #127290)

2025-04-05 Thread Petr Hosek via cfe-commits
@@ -835,8 +835,24 @@ class LLVM_LIBRARY_VISIBILITY UEFIX86_64TargetInfo public: UEFIX86_64TargetInfo(const llvm::Triple &Triple, const TargetOptions &Opts) : UEFITargetInfo(Triple, Opts) { +// The UEFI spec does not mandate specific C++ ABI, integer widths, or +

[clang] [clang] Merge gtest binaries into AllClangUnitTests (PR #134196)

2025-04-04 Thread Petr Hosek via cfe-commits
@@ -77,3 +104,25 @@ add_subdirectory(Index) add_subdirectory(InstallAPI) add_subdirectory(Serialization) add_subdirectory(Support) + + +# If we're doing a single merged clang unit test binary, add that target after +# all the previous subdirectories have been processed. +get_pr

[clang] [cmake] Refactor clang unittest cmake (PR #133545)

2025-03-31 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. This is definitely an improvement over status quo! Ideally, developers wouldn't have to list Clang libraries separately from other libraries but that would require some non-trivial build system refactoring that would be better done in fo

[clang-tools-extra] [clang-doc] Allow setting a base directory for hosted pages (PR #132482)

2025-03-27 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/132482 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Format test files (PR #132428)

2025-03-24 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/132428 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Avoid deref of invalid std::optional (PR #131939)

2025-03-19 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/131939 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix UEFI Target info (PR #127290)

2025-03-17 Thread Petr Hosek via cfe-commits
@@ -835,16 +835,22 @@ class LLVM_LIBRARY_VISIBILITY UEFIX86_64TargetInfo public: UEFIX86_64TargetInfo(const llvm::Triple &Triple, const TargetOptions &Opts) : UEFITargetInfo(Triple, Opts) { +LongWidth = LongAlign = 32; +DoubleAlign = LongLongAlign = 64; +Int

[clang] [Fuchsia] Support PGO (PR #128680)

2025-03-17 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/128680 >From 0662cddc6837c281c102995e2789bb0f81adb415 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Fri, 7 Feb 2025 08:49:18 -0800 Subject: [PATCH 1/3] [Fuchsia] Support PGO Enable 2-stage builds with PGO. --- ..

[clang] [clang] Fix UEFI Target info (PR #127290)

2025-03-16 Thread Petr Hosek via cfe-commits
@@ -835,19 +835,39 @@ class LLVM_LIBRARY_VISIBILITY UEFIX86_64TargetInfo public: UEFIX86_64TargetInfo(const llvm::Triple &Triple, const TargetOptions &Opts) : UEFITargetInfo(Triple, Opts) { +LongWidth = LongAlign = 32; +DoubleAlign = LongLongAlign = 64; +Int

[clang] [Fuchsia] Add llc to toolchain (PR #130999)

2025-03-12 Thread Petr Hosek via cfe-commits
petrhosek wrote: Can you check the toolchain binary size increase? Is `llc` included in the `llvm` binary? https://github.com/llvm/llvm-project/pull/130999 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/

[clang] [Driver] Teach Barmetal toolchain about GCC installation(1/3) (PR #121829)

2025-02-27 Thread Petr Hosek via cfe-commits
@@ -110,20 +111,93 @@ static std::string computeBaseSysRoot(const Driver &D, bool IncludeTriple) { return std::string(SysRootDir); } +// GCC sysroot here means form sysroot from either --gcc-install-dir, or from +// --gcc-toolchain or if the toolchain is installed alongside

[clang] [Driver] Teach Barmetal toolchain about GCC installation(1/3) (PR #121829)

2025-02-27 Thread Petr Hosek via cfe-commits
@@ -110,20 +111,93 @@ static std::string computeBaseSysRoot(const Driver &D, bool IncludeTriple) { return std::string(SysRootDir); } +// GCC sysroot here means form sysroot from either --gcc-install-dir, or from +// --gcc-toolchain or if the toolchain is installed alongside

[clang] [Driver] Teach Barmetal toolchain about GCC installation(1/3) (PR #121829)

2025-02-27 Thread Petr Hosek via cfe-commits
@@ -110,20 +111,93 @@ static std::string computeBaseSysRoot(const Driver &D, bool IncludeTriple) { return std::string(SysRootDir); } +// GCC sysroot here means form sysroot from either --gcc-install-dir, or from +// --gcc-toolchain or if the toolchain is installed alongside

[clang] [Driver] Teach Barmetal toolchain about GCC installation(1/3) (PR #121829)

2025-02-27 Thread Petr Hosek via cfe-commits
@@ -97,7 +97,8 @@ static bool findRISCVMultilibs(const Driver &D, return false; } -static std::string computeBaseSysRoot(const Driver &D, bool IncludeTriple) { +static std::string computeInstalledToolchainSysRoot(const Driver &D, petrhosek wrote: Can we avo

[clang] [Driver] Teach Barmetal toolchain about GCC installation(1/3) (PR #121829)

2025-02-27 Thread Petr Hosek via cfe-commits
@@ -110,20 +111,93 @@ static std::string computeBaseSysRoot(const Driver &D, bool IncludeTriple) { return std::string(SysRootDir); } +// GCC sysroot here means form sysroot from either --gcc-install-dir, or from +// --gcc-toolchain or if the toolchain is installed alongside

[clang] [clang] Alias cc modifier to c (PR #127719)

2025-02-26 Thread Petr Hosek via cfe-commits
petrhosek wrote: > It seems like for gcc at least, IIUC, `cc` does a bit more than `c` so while > we are supporting `cc` for compatibility we are not fully supporting it? > Specifically: > > `except try harder to print it with no punctuation` > > Perhaps we should document that in the comment

[clang] [CodeGen] Ensure relative vtables use llvm.type.checked.load.relative (PR #126785)

2025-02-26 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. Can you update the PR description and explain why this is desirable? https://github.com/llvm/llvm-project/pull/126785 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.or

[clang] [clang] Alias cc modifier to c (PR #127719)

2025-02-26 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/127719 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Fuchsia] Support PGO (PR #128680)

2025-02-26 Thread Petr Hosek via cfe-commits
petrhosek wrote: > LGTM. This seems to work locally for me, but I haven't tested w/ cross > compiling. Is that still potentially an issue? It's not addressed since that's going to require more changes, I assume we'll disable PGO on cross-compiling builders by not setting `FUCHSIA_ENABLE_PGO`.

[clang] [Fuchsia] Support PGO (PR #128680)

2025-02-25 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/128680 Enable 2-stage builds with PGO. >From 0662cddc6837c281c102995e2789bb0f81adb415 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Fri, 7 Feb 2025 08:49:18 -0800 Subject: [PATCH 1/2] [Fuchsia] Support PGO Enable

[clang] [Fuchsia] Support PGO (PR #128680)

2025-02-25 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/128680 >From 0662cddc6837c281c102995e2789bb0f81adb415 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Fri, 7 Feb 2025 08:49:18 -0800 Subject: [PATCH 1/2] [Fuchsia] Support PGO Enable 2-stage builds with PGO. --- ..

[clang] [CMake] Fix variable name (PR #127967)

2025-02-20 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/127967 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][perf-training] Support excluding LLVM build from PGO training (PR #126876)

2025-02-19 Thread Petr Hosek via cfe-commits
@@ -11,6 +11,7 @@ config.python_exe = "@Python3_EXECUTABLE@" config.cmake_exe = "@CMAKE_COMMAND@" config.llvm_src_dir ="@CMAKE_SOURCE_DIR@" config.cmake_generator ="@CMAKE_GENERATOR@" +config.use_llvm_build = @CLANG_PGO_TRAINING_USE_LLVM_BUILD@ petrhosek wrote:

[clang] [CMake] Fix variable name (PR #127967)

2025-02-19 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/127967 This was accidentaly introduced in #126876. >From 811f3ce860a5e544000166ccd06df3bb8cf5ec6b Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Thu, 20 Feb 2025 07:39:23 + Subject: [PATCH] [CMake] Fix variable

[clang] [clang][perf-training] Support excluding LLVM build from PGO training (PR #126876)

2025-02-19 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/126876 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][perf-training] Support excluding LLVM build from PGO training (PR #126876)

2025-02-12 Thread Petr Hosek via cfe-commits
petrhosek wrote: @tstellar We're trying to build a more minimal corpus that would address the issues I listed with @ilovepi. In the meantime, it'd be helpful to have this option since the current implementation actually breaks on our builders (which don't have host toolchain and sysroot instal

[clang] [clang][perf-training] Support excluding LLVM build from PGO training (PR #126876)

2025-02-12 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/126876 Using LLVM build itself for PGO training is convenient and a great starting point but it also has several issues: * LLVM build implicitly depends on tools other than CMake and C/C++ compiler and if those too

[clang] [profile] Add a clang option -fprofile-continuous that enables continuous instrumentation profiling mode (PR #124353)

2025-02-10 Thread Petr Hosek via cfe-commits
petrhosek wrote: > Just saw this in LLVM weekly. But this is not supported on Windows right? > Only the UNIX platforms that can mmap? In that case it the limitation needs > to be documented It is supported! We have [an `mmap` implementation for Windows](https://github.com/llvm/llvm-project/bl

[clang] [Fuchsia] Disable building runtimes with LTO (PR #126306)

2025-02-10 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/126306 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Revert "[Fuchsia] Support PGO" (PR #126293)

2025-02-07 Thread Petr Hosek via cfe-commits
petrhosek wrote: LGTM https://github.com/llvm/llvm-project/pull/126293 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Fuchsia] Support PGO (PR #120323)

2025-02-07 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek ready_for_review https://github.com/llvm/llvm-project/pull/120323 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Fuchsia] Support PGO (PR #120323)

2025-02-07 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/120323 >From 025652fd24c1dd13a3d628bd1a56c26e715badaa Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Fri, 6 Mar 2020 17:23:35 -0800 Subject: [PATCH] [Fuchsia] Support PGO Enable 2-stage builds with PGO. --- .../ca

[clang] [compiler-rt] [profile] Add `%b` `LLVM_PROFILE_FILE` option for binary ID (PR #123963)

2025-02-06 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/123963 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [compiler-rt] [profile] Add `%b` `LLVM_PROFILE_FILE` option for binary ID (PR #123963)

2025-02-06 Thread Petr Hosek via cfe-commits
@@ -2916,6 +2917,12 @@ instrumentation: $ LLVM_PROFILE_FILE="code-%m.profraw" ./code + Although rare, binary signatures used by the ``%m`` specifier can have + collisions. In this case, the ``%b`` specifier, which expands to the binary + ID (build ID), can be added

[clang-tools-extra] [clang-doc] Precommit end-to-end test for `--repository` option (PR #122565)

2025-02-05 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/122565 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PGO] Add a clang option -fprofile-continuous that enables PGO continuous mode (PR #124353)

2025-02-05 Thread Petr Hosek via cfe-commits
petrhosek wrote: > I believe all comments have been addressed. friendly ping. @petrhosek any > feedback please? The high-level comment is that the continuous mode isn't PGO specific, it was actually originally developed primarily for coverage, although it can be used for PGO as well due to th

[clang] [fuchsia][cmake] Add runtimes for cortex-m4 for the Fuchsia toolchain (PR #123258)

2025-01-16 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/123258 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CMake] Add a cache file for building a highly-optimized LLVM toolchain (PR #117802)

2025-01-15 Thread Petr Hosek via cfe-commits
petrhosek wrote: These cache files seem to be largely the same as [PGO.cmake](https://github.com/llvm/llvm-project/blob/4cec0ba92955c353c52efe728b2cfef3fbdf60f8/clang/cmake/caches/PGO.cmake), [PGO-stage2.cmake](https://github.com/llvm/llvm-project/blob/04b002bbb838bc502bd6d5f602af95efd6cc96b3/

[compiler-rt] [libunwind] [libunwind][cmake] Compile _Unwind* routines with -fexceptions (PR #121819)

2025-01-15 Thread Petr Hosek via cfe-commits
@@ -20,7 +20,12 @@ set(LIBUNWIND_C_SOURCES ) set_source_files_properties(${LIBUNWIND_C_SOURCES} PROPERTIES - COMPILE_FLAGS "-std=c99") + # We need to set `-fexceptions` here so that key +

[clang] Fix a cmake error when using the Xcode generator. (PR #119403)

2025-01-08 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/119403 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver][UEFI] Enable Microsoft extensions (PR #121875)

2025-01-08 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/121875 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver][UEFI] Enable Microsoft extensions (PR #121875)

2025-01-07 Thread Petr Hosek via cfe-commits
petrhosek wrote: Can you include a test as well? https://github.com/llvm/llvm-project/pull/121875 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver][UEFI] Enable Microsoft extensions (PR #121875)

2025-01-07 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek edited https://github.com/llvm/llvm-project/pull/121875 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libunwind] [libunwind][cmake] Compile _Unwind* routines with -fexceptions (PR #121819)

2025-01-07 Thread Petr Hosek via cfe-commits
@@ -20,7 +20,7 @@ set(LIBUNWIND_C_SOURCES ) set_source_files_properties(${LIBUNWIND_C_SOURCES} PROPERTIES - COMPILE_FLAGS "-std=c99") + COMPILE_FLAGS "-std=c99 -fexceptions") -

[clang] [clang] Introduce a new UEFI target predefine. (PR #111719)

2024-12-20 Thread Petr Hosek via cfe-commits
petrhosek wrote: Can you include a test for this change? https://github.com/llvm/llvm-project/pull/111719 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Introduce a new UEFI target predefine. (PR #111719)

2024-12-20 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/111719 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Introduce a new UEFI target predefine. (PR #111719)

2024-12-20 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek ready_for_review https://github.com/llvm/llvm-project/pull/111719 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] fix uefi target for aarch64 & x86_64 (PR #120632)

2024-12-20 Thread Petr Hosek via cfe-commits
@@ -790,7 +790,9 @@ template class LLVM_LIBRARY_VISIBILITY UEFITargetInfo : public OSTargetInfo { protected: void getOSDefines(const LangOptions &Opts, const llvm::Triple &Triple, -MacroBuilder &Builder) const override {} +MacroBuilder

[clang] [libcxx] [clang][driver] Cleanup UEFI toolchain driver (PR #111473)

2024-12-20 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/111473 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][cmake] Apply bolt optimizations as part of the clang target (PR #119896)

2024-12-19 Thread Petr Hosek via cfe-commits
@@ -558,7 +560,107 @@ def genOrderFile(args): return 0 +def bolt_optimize(args): +parser = argparse.ArgumentParser("%prog [options] ") +parser.add_argument("--method") +parser.add_argument("--input") +parser.add_argument("--instrumented-output") +pars

[clang] [clang][cmake] Apply bolt optimizations as part of the clang target (PR #119896)

2024-12-19 Thread Petr Hosek via cfe-commits
@@ -134,3 +147,42 @@ if(CLANG_ORDER_FILE AND set_target_properties(clang PROPERTIES LINK_DEPENDS ${CLANG_ORDER_FILE}) endif() endif() + +if (CLANG_BOLT AND NOT LLVM_BUILD_INSTRUMENTED) + # Add a clang-bolt target for backwards compatibility. + add_custom_target(clang-bo

[clang] [compiler-rt] [driver] Fix sanitizer libc++ runtime linking (PR #120370)

2024-12-18 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/120370 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2024-12-17 Thread Petr Hosek via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] [Fuchsia] Support PGO (PR #120323)

2024-12-17 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/120323 Enable 2-stage builds with PGO. >From 025652fd24c1dd13a3d628bd1a56c26e715badaa Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Fri, 6 Mar 2020 17:23:35 -0800 Subject: [PATCH] [Fuchsia] Support PGO Enable 2-s

[clang] [libcxx] [libcxx] Support for using timespec_get (PR #117362)

2024-12-17 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/117362 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [libcxx] Support for using timespec_get (PR #117362)

2024-12-17 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/117362 >From f9f2fb604d49496fbbc65948d657de7f2638123c Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Fri, 22 Nov 2024 10:47:06 -0800 Subject: [PATCH 1/2] [libcxx] Support for using timespec_get clock_gettime is a P

[clang-tools-extra] [clang-doc][NFC] Rename CHECK prefix for YAML (PR #119810)

2024-12-12 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/119810 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Merging RISCVToolChain and BareMetal toolchains (PR #118809)

2024-12-12 Thread Petr Hosek via cfe-commits
petrhosek wrote: > > I think this change could be made a lot smaller by doing a clean up first, > > bringing the BareMetal driver closer to other drivers, before attempting to > > merge the RISCVToolChain driver into it. > > Could you describe in a bit more detail which bits you think need to

[clang] [clang][Driver] Allow `-fstack-clash-protection` for Fuchsia targets (PR #119633)

2024-12-11 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/119633 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libc] [libc] Support baremetal libc on aarch64 (PR #118691)

2024-12-09 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/118691 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Merging RISCVToolChain and BareMetal toolchains (PR #118809)

2024-12-06 Thread Petr Hosek via cfe-commits
petrhosek wrote: The `BareMetal` driver currently isn't very idiomatic (compared to other drivers like `Generic_GCC`) and duplicates a lot of the logic that has been already factored out in other drivers. I think this change could be made a lot smaller by doing a clean up first, bringing the `

[clang] [Driver] Normalize the baremetal handling of libc++ and runtimes (PR #101259)

2024-12-06 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/101259 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][perf-training] Fix clean command in perf-helper.py (PR #118978)

2024-12-06 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/118978 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Merging RISCVToolChain and BareMetal toolchains (PR #118809)

2024-12-06 Thread Petr Hosek via cfe-commits
@@ -291,6 +365,36 @@ BareMetal::OrderedMultilibs BareMetal::getOrderedMultilibs() const { return llvm::reverse(Default); } +ToolChain::CXXStdlibType BareMetal::GetDefaultCXXStdlibType() const { + if (getTriple().isRISCV()) { +return GCCInstallation.isValid() ? ToolChai

[clang] [Driver] Normalize the baremetal handling of libc++ and runtimes (PR #101259)

2024-12-06 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/101259 >From f20e9d0bc3fc66ebcda8286682a2d38e006bb9d0 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Wed, 24 Jul 2024 10:47:49 -0700 Subject: [PATCH] [Driver] Normalize the baremetal handling of libc++ and runtimes

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2024-12-05 Thread Petr Hosek via cfe-commits
@@ -0,0 +1,113 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2024-12-05 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek edited https://github.com/llvm/llvm-project/pull/105893 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ARM] disable frame pointers by default for bare metal ARM targets (PR #117140)

2024-12-05 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/117140 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver][Fuchsia] Avoid "argument unused" warnings (PR #118416)

2024-12-04 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/118416 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Fuchsia] Remove libc from LLVM_ENABLE_PROJECTS (PR #118704)

2024-12-04 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/118704 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libc] [libc] Support baremetal libc on aarch64 (PR #118691)

2024-12-04 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/118691 We have users that target baremetal aarch64. >From b9a09c6a5b4966ff7e614ace8a0e6a5a6a1916f4 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Wed, 4 Dec 2024 00:47:10 -0800 Subject: [PATCH] [Fuchsia] Enable bar

[clang] [clang][ARM] disable frame pointers by default for bare metal ARM targets (PR #117140)

2024-12-02 Thread Petr Hosek via cfe-commits
@@ -128,12 +128,14 @@ BareMetal::BareMetal(const Driver &D, const llvm::Triple &Triple, } } +namespace clang { +namespace driver { +namespace toolchains { /// Is the triple {arm,armeb,thumb,thumbeb}-none-none-{eabi,eabihf} ? -static bool isARMBareMetal(const llvm::Triple &

[clang] [CMake] Add a cache file for building a highly-optimized LLVM toolchain (PR #117802)

2024-11-26 Thread Petr Hosek via cfe-commits
petrhosek wrote: > The runtimes build already builds the toolchain and then builds the runtimes > with the just-built toolchain. Can we build the LTO-optimized libc++ as part > of stage1 and have stage2 be what the current stage3 is, to avoid any > redundancy? I really like the direction here

[clang] [libcxx] [libcxx] Support for using timespec_get (PR #117362)

2024-11-22 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/117362 clock_gettime is a POSIX API that may not be available on platforms like baremetal; timespec_get is the C11 equivalent. This change adds support for using timespec_get instead of clock_gettime to improve comp

[clang] [Fuchsia][CMake] Enable new libc header gen (PR #116938)

2024-11-21 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/116938 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [compiler-rt] [libcxx] [llvm] [libc++] Replace LIBCXX_ENABLE_STATIC_ABI_LIBRARY & friends by a new LIBCXX_CXX_ABI choice (PR #112978)

2024-11-20 Thread Petr Hosek via cfe-commits
@@ -230,11 +230,22 @@ else() endif() set(LIBCXX_SUPPORTED_ABI_LIBRARIES none libcxxabi system-libcxxabi libcxxrt libstdc++ libsupc++ vcruntime) -set(LIBCXX_CXX_ABI "${LIBCXX_DEFAULT_ABI_LIBRARY}" CACHE STRING "Specify C++ ABI library to use. Supported values are ${LIBCXX_SUP

[clang] [Fuchsia][CMake] Enable new libc header gen (PR #116938)

2024-11-20 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/116938 All issues blocking this were resolved. >From 3ec4710a6f362e1d63b854c80ad2d7dcb40a24b0 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Wed, 13 Nov 2024 11:45:54 -0800 Subject: [PATCH] [Fuchsia][CMake] Enable

[clang] Disable LIBCXX_INCLUDE_BENCHMARKS in Fuchsia cmake (PR #116446)

2024-11-15 Thread Petr Hosek via cfe-commits
@@ -31,6 +31,7 @@ set(LLVM_STATIC_LINK_CXX_STDLIB ON CACHE BOOL "") set(LLVM_USE_RELATIVE_PATHS_IN_FILES ON CACHE BOOL "") set(LLDB_ENABLE_CURSES OFF CACHE BOOL "") set(LLDB_ENABLE_LIBEDIT OFF CACHE BOOL "") +set(LIBCXX_INCLUDE_BENCHMARKS OFF CACHE BOOL "") pet

[clang] [Fuchsia] Include runtimes for armv8.1m.main-none-eabi (PR #116420)

2024-11-15 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/116420 These are needed by some of our users. >From 028021ded3dee3f55ba26540f5c9cf1a1e8cbb36 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Tue, 12 Nov 2024 19:50:46 + Subject: [PATCH] [Fuchsia] Include runtime

[clang] [Fuchsia] Include runtimes for armv8.1m.main-none-eabi (PR #116420)

2024-11-15 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/116420 >From 028021ded3dee3f55ba26540f5c9cf1a1e8cbb36 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Tue, 12 Nov 2024 19:50:46 + Subject: [PATCH 1/2] [Fuchsia] Include runtimes for armv8.1m.main-none-eabi These

[clang] [Fuchsia] Include runtimes for armv8.1m.main-none-eabi (PR #116420)

2024-11-15 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/116420 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [libcxxabi] [Fuchsia][cmake] Allow using FatLTO when building runtimes (PR #112277)

2024-11-15 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/112277 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Revert "[Fuchsia][CMake] Enable new libc header gen" (PR #116174)

2024-11-13 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/116174 Reverts llvm/llvm-project#102371 >From be995b825da9c12c8fead48d2e5ba575f154bddf Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Wed, 13 Nov 2024 23:32:07 -0800 Subject: [PATCH] Revert "[Fuchsia][CMake] Enable

[clang] Revert "[Fuchsia][CMake] Enable new libc header gen" (PR #116174)

2024-11-13 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/116174 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Fuchsia][CMake] Enable new libc header gen (PR #102371)

2024-11-13 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/102371 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Fuchsia][CMake] Enable new libc header gen (PR #102371)

2024-11-12 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/102371 >From 6dbb8be2352d0cdad44d293f7cc5c13f55ec243d Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Wed, 7 Aug 2024 07:40:09 + Subject: [PATCH 1/2] [Fuchsia][CMake] Enable new libc header gen All issues blocki

[clang] [Fuchsia][CMake] Enable new libc header gen (PR #102371)

2024-11-12 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/102371 >From 6dbb8be2352d0cdad44d293f7cc5c13f55ec243d Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Wed, 7 Aug 2024 07:40:09 + Subject: [PATCH] [Fuchsia][CMake] Enable new libc header gen All issues blocking t

[clang] [compiler-rt] [libcxx] [llvm] [libc++] Replace LIBCXX_ENABLE_STATIC_ABI_LIBRARY & friends by a new LIBCXX_CXX_ABI choice (PR #112978)

2024-11-05 Thread Petr Hosek via cfe-commits
@@ -230,11 +230,22 @@ else() endif() set(LIBCXX_SUPPORTED_ABI_LIBRARIES none libcxxabi system-libcxxabi libcxxrt libstdc++ libsupc++ vcruntime) -set(LIBCXX_CXX_ABI "${LIBCXX_DEFAULT_ABI_LIBRARY}" CACHE STRING "Specify C++ ABI library to use. Supported values are ${LIBCXX_SUP

[clang] [compiler-rt] [libcxx] [llvm] [libc++] Replace LIBCXX_ENABLE_STATIC_ABI_LIBRARY & friends by a new LIBCXX_CXX_ABI choice (PR #112978)

2024-11-05 Thread Petr Hosek via cfe-commits
@@ -230,11 +230,22 @@ else() endif() set(LIBCXX_SUPPORTED_ABI_LIBRARIES none libcxxabi system-libcxxabi libcxxrt libstdc++ libsupc++ vcruntime) -set(LIBCXX_CXX_ABI "${LIBCXX_DEFAULT_ABI_LIBRARY}" CACHE STRING "Specify C++ ABI library to use. Supported values are ${LIBCXX_SUP

[compiler-rt] [libunwind] [llvm] [cmake] Remove obsolete files, docs and CMake variables related to the standalone build (PR #112741)

2024-11-04 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek commented: LGTM https://github.com/llvm/llvm-project/pull/112741 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [libcxxabi] [Fuchsia][cmake] Allow using FatLTO when building runtimes (PR #112277)

2024-10-31 Thread Petr Hosek via cfe-commits
petrhosek wrote: I think this is due to https://github.com/llvm/llvm-project/blob/c3edeaa61bf0e7faed6c26f693b4fcd9102ba1ec/compiler-rt/lib/builtins/cpu_model/aarch64/lse_atomics/fuchsia.inc#L7 which I believe is yet another instance of #56070. https://github.com/llvm/llvm-project/pull/112277 _

[clang] CMake cache file for building Pico SDK toolchain (PR #113267)

2024-10-21 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek updated https://github.com/llvm/llvm-project/pull/113267 >From 781d226916e6bc477494f707085b9ccab72befb6 Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Mon, 21 Oct 2024 23:24:11 -0700 Subject: [PATCH 1/2] CMake cache file for building Pico SDK toolchain This cache

[clang] CMake cache file for building Pico SDK toolchain (PR #113267)

2024-10-21 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/113267 This cache file demonstrates how to build a complete baremetal Clang/LLVM toolchain that can be used to build the Pico SDK. >From 781d226916e6bc477494f707085b9ccab72befb6 Mon Sep 17 00:00:00 2001 From: Petr H

[clang] [HIP] Suport LLVM Driver (PR #112249)

2024-10-14 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek closed https://github.com/llvm/llvm-project/pull/112249 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HIP] Suport LLVM Driver (PR #112249)

2024-10-14 Thread Petr Hosek via cfe-commits
@@ -466,7 +467,7 @@ void HIP::constructGenerateObjFileFromHIPFatBinary( "-o", Output.getFilename(), "-x", "assembler", ObjinFile, "-c"}; - const char *Clang = Args.MakeArgString(C.getDriver().ClangE

[clang] [HIP] Suport LLVM Driver (PR #112249)

2024-10-14 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/112249 This addresses an issue introduced in #112041. >From 8f2e6b76edf09812cfb9a26b13ebcadf711f8b8e Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Mon, 14 Oct 2024 18:49:29 + Subject: [PATCH] [HIP] Suport LLVM

[clang] [HIP] Replace use of `llvm-mc` with `clang` (PR #112041)

2024-10-14 Thread Petr Hosek via cfe-commits
petrhosek wrote: > > > @petrhosek Can someone explain why the clang executable in these tests is > > > called `llvm` on the Fuchsia bots? > > > > > > We enable the > > [`LLVM_TOOL_LLVM_DRIVER_BUILD`](https://github.com/llvm/llvm-project/blob/48deb3568eb2452ff385b04b8f71c34121f47387/clang/cmak

  1   2   3   4   5   6   7   8   9   10   >