- Apr 18, 2023
-
-
Eli Friedman authored
This is mostly useful for ARM64EC, which uses such symbols extensively. One interesting quirk of ARM64EC is that we need to be able to emit weak symbols that point at each other (so if either symbol is defined elsewhere, both symbols point at the definition). This required a few changes to the way we handle weak symbols on Windows. Differential Revision: https://reviews.llvm.org/D145208
-
Nick Desaulniers authored
This reverts commit d6d30dd9. These helpers were added to be used by LLVMDemangle, which would be a layering violation for that to depend on LLVMSupport. Undo this commit, and I'll these these directly in LLVMDemangle. Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D148547
-
Caslyn Tonelli authored
Reduce `PrimaryRegionSizeLog` to 28U to be compatible with a 38bit user address space on the fuchsia-riscv platform. `PrimaryGroupSizeLog` is reduced to 19 to preserve 512 BatchGroups per region. This change can be tested on Fuchsia with: ``` fx set --auto-dir bringup.riscv64 --with //bundles:boot_tests \ fx build bundles:boot_tests \ fx run-boot-test --args={-s,1} boot-libc-unittests \ --cmdline='--gtest_filter=-*DeathTest*:PthreadGetSet*:ScudoSecondaryTest*' ``` The gtest filter ignores pthread and death tests due to non-scudo related issues on fuchsia-riscv (ScudoSecondaryTest includes a death check). Related Ticket: https://fxbug.dev/125263 Differential Revision: https://reviews.llvm.org/D148475 -
Congcong Cai authored
Fixed: https://github.com/llvm/llvm-project/issues/62113 Add addtional check in `visitSelectInst` to: 1. match `select(X|Y==0, X, X|Y)` and replaced with `X|Y` 2. match `select(X&Y==-1, X, X&Y)` and replaced with `X&Y` alive proof: https://alive2.llvm.org/ce/z/4qHmv- https://alive2.llvm.org/ce/z/c2MBGy Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D148275
-
Congcong Cai authored
Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D148562
-
Mikhail R. Gadelha authored
Partial revert of commit ee917996. I can't reproduce the error locally, so let's revert it to keep the bots happy.
-
Valentin Clement authored
Use the assembly format with custom parser/printer for specific clauses instead of a full custom parser/printer. Reviewed By: PeteSteinfeld Differential Revision: https://reviews.llvm.org/D148391
-
Ashay Rane authored
The `__builtin_bswap{32,64}()` builtins (introduced in commit e07a421d) are missing from MSVC, which causes build errors when compiling LLDB on Windows (tested with MSVC 19.34.31943.0). This patch replaces the builtins with either MSVC's `_byteswap_u{long,64}()` or the original builtins, or the `bswap_{32,64}()` functions from byteswap.h, depending on which ones are available. Reviewed By: bulbazord Differential Revision: https://reviews.llvm.org/D148541 -
Manoj Gupta authored
This reverts commit 7fc0b304. Causes a clang hang when building xz utils, github issue #62187.
-
Mikhail R. Gadelha authored
This patch updates the list of supported libs according to the latest changes to x86_64 Reviewed By: sivachandra Differential Revision: https://reviews.llvm.org/D147961
-
Jack Grigg authored
Reviewed By: kwk Differential Revision: https://reviews.llvm.org/D143535
-
Jonas Devlieghere authored
- Separate the two test and only have TestSymbolFileJSON rely on strip. - Use different file names to make sure LLDB reloads the module. This should address all the post commit review from D148062.
-
Lang Hames authored
This allows the subsequent code to access the E_IDENT fields, which will be used in the upcoming JITLink ppc64 backend (https://reviews.llvm.org/D148192).
-
Shraiysh Vaishay authored
This patch replaces the uses of PointerUnion.is function by llvm::isa, PointerUnion.get function by llvm::cast, and PointerUnion.dyn_cast by llvm::dyn_cast_if_present. This is according to the FIXME in the definition of the class PointerUnion. This patch does not remove them as they are being used in other subprojects. Reviewed By: mehdi_amini Differential Revision: https://reviews.llvm.org/D148449
-
mydeveloperday authored
as `is` is a keyword in C# ensure there is always a space before the `[` regardless of `SpaceBeforeSquareBrackets` setting Fixes: #61965 https://github.com/llvm/llvm-project/issues/61965 Reviewed By: owenpan, HazardyKnusperkeks Differential Revision: https://reviews.llvm.org/D148472
-
Anton Korobeynikov authored
This reverts commit 82c02b73. Apparently, the original patch was not rebased onto `main
-
Lei Zhang authored
We need to create a new type with transposed shape after transposing the operand in `CanonicalizeContractMatmulToMMT`. Reviewed By: kuhar, dcaballe Differential Revision: https://reviews.llvm.org/D148470
-
Jonas Devlieghere authored
This reverts commit 9395cf06 because it breaks the modules build: STLFunctionalExtras.h:54:3: error: 'llvm::function_ref<std::__1::optional<std::__1::basic_string<char>> (llvm::StringRef, llvm::StringRef)>::function_ref' from module 'LLVM_Utils.ADT.STLFunctionalExtras' is not present in definition of 'llvm::function_ref<std::__1::optional<std::__1::basic_string<char>> (llvm::StringRef, llvm::StringRef)>' in module 'LLVM_Utils.ADT.STLFunctionalExtras' https://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/53806/
-
Anton Korobeynikov authored
Add MSP430 to the list of available targets, implement MSP430 ABI, add support for debugging targets with 16-bit address size. The update is intended for use with MSPDebug, a GDB server implementation for MSP430. Reviewed By: bulbazord, DavidSpickett Differential Revision: https://reviews.llvm.org/D146965
-
Yitzhak Mandelbaum authored
Adjusts the matchers in the optional model to avoid dependency on internal implementation details of libc++'s `std::optional`. In the process, factors out the code to check the name of these types so that it's shared throughout. Differential Revision: https://reviews.llvm.org/D148377
-
Yitzhak Mandelbaum authored
This patch refines the matching of the relevant optional types to anchor on the global namespace. Previously, we could match anything with the right name (e.g. `base::Optional`) even if nested within other namespaces. This over matching resulted in an assertion violation when _different_ `base::Optional` was encountered nested inside another namespace. Fixes issue #57036. Differential Revision: https://reviews.llvm.org/D148344
-
Markus Mützel authored
Function arguments or return values that are complex floating point values aren't correctly lowered for Windows x86 32-bit and 64-bit targets. See: https://github.com/llvm/llvm-project/issues/61976 Add targets that are specific for these platforms and OS. With thanks to @mstorsjo for pointing out the fix. Reviewed By: vzakhari Differential Revision: https://reviews.llvm.org/D147768
-
Han Zhu authored
V2: Fix cmake error when -DLLVM_APPEND_VC_REV=OFF Clang may be built in an environment where Git is not available. In our case, Clang is part of a larger monorepo which is not Git-based, and GenerateVersionFromVCS was not able to get source info. Provide options to pass in repo and revision info from cmake. ``` cmake \ -DCLANG_VC_REPOSITORY=abc://repo.url.com \ -DCLANG_VC_REVISION=abcd1234 \ ... ``` This would allow us to prepare the source info beforehand and pass it to the clang binary. Differential Revision: https://reviews.llvm.org/D148262
-
Snehasish Kumar authored
When no --profiled-binary flag is provided we can print out the build ids of the modules in the profile. This can help the user fetch the correct binary from e.g. remote object store. Reviewed By: tejohnson Differential Revision: https://reviews.llvm.org/D148301
-
Siva Chandra Reddy authored
Differential Revision: https://reviews.llvm.org/D148454
-
Peiming Liu authored
Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D147670
-
Alexandros Lamprineas authored
Optionally enabled just like integer and floating point arguments. Differential Revision: https://reviews.llvm.org/D145374
-
Caslyn Tonelli authored
`dieOnError` in fuchsia.cpp takes the syscall name, status code, and relevant size parameter to describe what failed, the reason, and size context. Several different Fuchsia syscalls can fail underlying Scudo's map operation and gets hidden if using `dieOnMapUnmapError`. The reason for this change is to provide an error status code and more helpful information to debug failures.
-
Nikolas Klauser authored
Reviewed By: #libc, Mordante Spies: Mordante, libcxx-commits Differential Revision: https://reviews.llvm.org/D148466
-
John-Earnshaw authored
Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D148538
-
Eduard Zingerman authored
`BPF.td` is used to generate (among other things) `MCSubtargetInfo` setup function for BPF target. Specifically, the `BPFGenSubtargetInfo.inc` file: enum { ALU32 = 0, ... }; ... extern const llvm::SubtargetSubTypeKV BPFSubTypeKV[] = { { "generic", { { { 0x0ULL, ... } } }, ... }, { "probe", { { { 0x0ULL, ... } } }, ... }, { "v1", { { { 0x0ULL, ... } } }, ... }, { "v2", { { { 0x0ULL, ... } } }, ... }, { "v3", { { { 0x1ULL, ... } } }, ... }, }; ... static inline MCSubtargetInfo *createBPFMCSubtargetInfoImpl(...) { return new BPFGenMCSubtargetInfo(..., BPFSubTypeKV, ...); } The `SubtargetSubTypeKV` is defined in `MCSubtargetInfo.h` as: /// Used to provide key value pairs for feature and CPU bit flags. struct SubtargetSubTypeKV { const char *Key; ///< K-V key string FeatureBitArray Implies; ///< K-V bit mask FeatureBitArray TuneImplies; ///< K-V bit mask const MCSchedModel *SchedModel; ... } The first bit array specifies features enabled by default for a specific CPU. This commit makes sure that this information is communicated to `tablegen` and correct `BPFSubTypeKV` table is generated. This allows tools like `objdump` to detect available features when `--mcpu` flag is specified. Differential Revision: https://reviews.llvm.org/D148037 -
Zequan Wu authored
This fixes two problems: 1. When crossing compiling for windows on linux, source file path in debug info is concatenated with directory by host native separator ('/'). For windows local build, they are concatenated by '\'. This causes non-determinism bug. The solution here is to let `LangOptions.UseTargetPathSeparator` to control if we should use host native separator or not. 2. Objectfile path in CodeView also uses host native separator when generated. It's fixed by changing the path separator in `/Fo` to '\' if the path is not an absolute path when adding the `-object-file-name=` flag. Reviewed By: hans Differential Revision: https://reviews.llvm.org/D147256 -
Fangrui Song authored
Fix https://github.com/llvm/llvm-project/issues/56554 ``` #include "1.h" #include "2.h" int foo(); ``` Suppose that 1.h ends with a template function. When parsing the function, the `ParseFunctionDefinition` call after the TimeTraceScope object may consume a `r_brace` token and lex the end of file (1.h), resulting in an ExitFile event in SemaPPCallbacks::FileChanged. This event will call `llvm::timeTraceProfilerEnd();`, which incorrectly ends "ParseTemplate" instead of "Source" (1.h). Once 2.h has been fully parsed, the destructor of 1.h's TimeTraceScope object will end "Source" (1.h). This behavior erroneously extends the end of "Source" (1.h), which makes "Source" (2.h) appear to be nested inside "Source" (1.h). This bug is difficult to fix correctly in an elegant way, and we have two options: either end "ParseTemplate" when ending "Source" (1.h), or delay the ExitFile event. However, both approaches require complex code. For now, we can remove the "ParseTemplate" TimeTraceScope. This can be re-added if properly repaired. Reviewed By: anton-afanasyev Differential Revision: https://reviews.llvm.org/D148410
-
Peiming Liu authored
Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D147553
-
Thurston Dang authored
Reverting 364884e0 because it appears the sanitizers are not yet ready to be stressed out (build failures starting from https://lab.llvm.org/buildbot/#/builders/37/builds/21483).
-
Joseph Huber authored
The NVIDIA compilation path requires some special options. This is mostly because compilation is dependent on having a valid CUDA toolchain. We don't actually need the CUDA toolchain to create the exported `libcgpu.a` library because it's pure LLVM-IR. However, for some language features we need the PTX version to be set. This is normally set by checking the CUDA version, but without one installed it will fail to build. We instead choose a minimum set of features on the desired target, inferred from https://docs.nvidia.com/cuda/parallel-thread-execution/index.html#release-notes and the PTX refernece for functions like `nanosleep`. Reviewed By: tianshilei1992 Differential Revision: https://reviews.llvm.org/D148532
-
Han Zhu authored
Clang may be built in an environment where Git is not available. In our case, Clang is part of a larger monorepo which is not Git-based, and GenerateVersionFromVCS was not able to get source info. Provide options to pass in repo and revision info from cmake. ``` cmake \ -DCLANG_VC_REPOSITORY=abc://repo.url.com \ -DCLANG_VC_REVISION=abcd1234 \ ... ``` This would allow us to prepare the source info beforehand and pass it to the clang binary. Differential Revision: https://reviews.llvm.org/D148262
-
OCHyams authored
Prefix the variable with 'f' to match other 'f' options.
-
Lang Hames authored
This patch switches LLJIT's default JIT linker for ELF/x86-64 from RuntimeDyld to JITLink. Most clients should not be affected, but if you were explicitly accessing the old RTDyldObjectLinkingLayer (e.g. to install JITEventListeners) you will need to either force use of RuntimeDyld (following the example in llvm/examples/OrcV2Examples/LLJITWithCustomObjectLinkingLayer), or switch to using JITLink plugins instead.
-