- Jan 21, 2024
-
-
Hristo Hristov authored
Co-authored-by:Zingam <zingam@outlook.com>
-
Matthias Springer authored
The buffer deallocation pass checks the IR ("operation preconditions") to make sure that there is no IR that is unsupported. In such a case, the pass signals a failure. The pass now rejects all ops with unknown memory effects. We do not know whether such an op allocates memory or not. Therefore, the buffer deallocation pass does not know whether a deallocation op should be inserted or not. Memory effects are queried from the `MemoryEffectOpInterface` interface. Ops that do not implement this interface but have the `RecursiveMemoryEffects` trait do not have any side effects (apart from the ones that their nested ops may have). Unregistered ops are now rejected by the pass because they do not implement the `MemoryEffectOpInterface` and neither do we know if they have `RecursiveMemoryEffects` or not. All test cases that currently have unregistered ops are updated to use registered ops. -
FantasqueX authored
Currently, if `CLANG_HAVE_LIBXML` is defined, and the version of libxml2 is above 2.12.0, there will be two warnings when building clang. warning: initializing 'xmlErrorPtr' (aka 'struct _xmlError *') with an expression of type 'const xmlError *' (aka 'const struct _xmlError *') discards qualifiers Since this commit https://gitlab.gnome.org/GNOME/libxml2/-/commit/45470611b047db78106dcb2fdbd4164163c15ab7, libxml2 makes cmlGetLastError return a const error. This patch follows libxml2. Making the result a const pointer should be compatible with versions before 2.12.0. Tested on ArchLinux with libxml2 2.12.3 installed.
-
Matthias Springer authored
There is already a "block inserted" notification (in `OpBuilder::Listener`), so there should also be a "block removed" notification. The purpose of this change is to make the listener API more mature. There is currently a gap between what kind of IR changes can be made and what IR changes can be listened to. At the moment, the only way to inform listeners about "block removal" is to send a manual `notifyOperationModified` for the parent op (e.g., by wrapping the `eraseBlock(b)` method call in `updateRootInPlace(b->getParentOp())`). This tells the listener that *something* has changed, but it is somewhat of an API abuse.
-
Fangrui Song authored
nonlazybind is for declarations, not for definitions. We could test the behavior, but the output would be misleading.
-
Konstantin Varlamov authored
Introduce a new `argument-within-domain` category that covers cases where the given arguments make it impossible to produce a correct result (or create a valid object in case of constructors). While the incorrect result doesn't create an immediate problem within the library (like e.g. a null pointer dereference would), it always indicates a logic error in user code and is highly likely to lead to a bug in the program once the value is used.
-
Vitaly Buka authored
Follow up to #78862 These tests control hardening mode with `ADDITIONAL_COMPILE_FLAGS`, and always set modes which use on TRAP. So we don't need to check `libcpp-hardening-mode=fast`, and they must always fail with the current HWASAN implementation.
-
Aiden Grossman authored
This reverts commit aa04d2b7. Meant to push this to my fork and did not realize I was on main and not a separate branch.
-
Aiden Grossman authored
-
Fangrui Song authored
Prepare for -fno-plt implementation.
-
Hristo Hristov authored
Implements parts of: `P2637R3` https://wg21.link/P2637R3 (https://eel.is/c++draft/variant.visit) Implements: `variant.visit()` `variant.visit<R>()` The tests are as close as possible to the non-member function. To land after: https://github.com/llvm/llvm-project/pull/76268 --------- Co-authored-by:
Zingam <zingam@outlook.com>
-
ZhangYin authored
-
Aiden Grossman authored
This patch disables the mlgo-utils tests on Windows builders. MLGO is not currently supported on Windows. These tests were failing as some of them look for specific file paths and the path conventions are different between Linux and Windows.
-
Aiden Grossman authored
This patch updates the paths in the PR labelling config for the MLGO label. In particular, the path for the new mlgo-utils subfolder under llvm/utils has been added and two other files that were missed in the original introduction.
-
Aiden Grossman authored
The library files in the new mlgo-utils utilities folder only depend on absl.logging. The builtin Python logging library is a direct drop-in replacement here, so we can just change the include and drop the test dependency.
-
Kazu Hirata authored
-
Kazu Hirata authored
-
Kazu Hirata authored
-
Kazu Hirata authored
-
Kazu Hirata authored
-
Vassil Vassilev authored
This test demonstrates template instantiation via the interpreter code. In order to do that we can allocate the object on the stack and extend its lifetime by boxing it into a clang::Value. That avoids the subtle problem where we call the new operator on an object only known to the interpreter and we cannot destroy it from compiled code since there is not suitable facility in clang::Value yet. That should resolve the asan issues that was reported in llvm/llvm-project#76218.
-
Jerry Wu authored
Don't insert cast ops for ops in `vector.mask` region in `VectorDropLeadUnitDim`.
-
lntue authored
-
XDeme authored
… return type. The behavior now is consistent with the non template version. Enabled and updated old test.
-
Kazu Hirata authored
-
Kazu Hirata authored
-
Kazu Hirata authored
-
Kazu Hirata authored
-
Kazu Hirata authored
-
Vincent Lee authored
The InlineOrder Heap stores a CallBase ptr and InlineHistoryID pair. When running the `erase_if` method, InlineHistoryID is always returned with 0. Instead, we should be retrieving it from the `InlineHistoryMap` (similar to what is done in the `pop` implementation). This change is completely harmless because no one is using InlineHistoryID right now as part of the `erase_if` implementation which is currently only used in the ModuleInliner.
-
David Green authored
The added test case has a loop that is versioned, which has a use of the loop in an if block after the loop. The current code replaces all uses of the loop with the new version If, but only if the parent blocks match. As far as I can see it should be safe to replace all the uses, then construct the result for the If with op.op.
-
OldWorldOrdr authored
Find object files in library search path just like Apple's linker, this makes building with some older MacOS SDKs easier since clang runs with `-lcrt1.10.6.o`
-
Hristo Hristov authored
...in attempt to fix the FreeBSD CI. I noticed that suddenly some tests in the latest PRs fail to compile on FreeBSD (`SIGILL` and `SIGTRAP` not defined). This tries to resolve the issue. Co-authored-by:Zingam <zingam@outlook.com>
-
Vitaly Buka authored
After #77883, `fast` mode uses TRAP, and HWASAN replaces TRAP with abort or error exit code. On a quick looks it should be possible to avoid doing that in HWASAN, but historically this is convention for all sanitizers. Changing this behavior may break existing users. Other sanitizers are not affected because they don't install TRAP handlers by default. But if they do, they also replace TRAP with abort/exit.
-
XDeme authored
Fixes llvm/llvm-project#62904 `AlignArrayOfStructures: Left` combined with `SpacesInParentheses: true` causes the first cell of every row to have 1 additional space. We were only setting the first cell of the first row to be against the left brace, now every row will be against the left brace.
-
Hui authored
When I implemented `condition_variable_any::wait`, I missed the most important paragraph in the spec: > The following wait functions will be notified when there is a stop request on the passed stop_token. > In that case the functions return immediately, returning false if the predicate evaluates to false. From https://eel.is/c++draft/thread.condition#thread.condvarany.intwait-1. Fixes #76807
-
lntue authored
-
Daniil Dudkin authored
There is no automatic labeling for the Extra Clang Tools, except Clang-Tidy and ClangD.
-
LEE KYOUNGHEON authored
Module documentation improvement: prebuilt module location can be directly fetched via CMake variable. (#78405) CMake officially supports binary directory variable of installed dependency using `FetchContent`. According to the current documentation, it fetches `std` module and use its binary directory as hardcoded string, `${CMAKE_BINARY_DIR}/_deps/std-build`, however it can be replaced with `${std_BINARY_DIR}`. Reference: https://cmake.org/cmake/help/latest/module/FetchContent.html -
lntue authored
-