- Dec 09, 2021
-
-
Chuanqi Xu authored
According to [dcl.fct.def.coroutine]/p14: > If the evaluation of the expression promise.unhandled_exception() > exits via an exception, the coroutine is considered suspended at the > final suspend point. But this is not implemented in clang before. This patch would implement this feature by marking the coroutine as done at the place of coro.end(frame, /*InUnwindPath=*/true ). Reviewed By: rjmccall Differential Revision: https://reviews.llvm.org/D115219
-
Kito Cheng authored
- `vm` constraint is used for masking operand, which always v0. - Update testcase, only masking operand should use `vm`, vector mask operations should just use `vr` for any vector register. - Revise the description of `vm` constraint. - This patch also fix issue on RISCVRegisterInfo.td and RISCVISelLowering.cpp. RISCVRegisterInfo.td: - The first VT in the list must be the largest total size since the SelectionDAGBuilder uses the first register in the list as the canonical type for the register. RISCVISelLowering.cpp: - Fix RISCVTargetLowering::splitValueIntoRegisterParts and RISCVTargetLowering::joinRegisterPartsIntoValue for handling vectors with different total size, that will happened on fractional LMUL since fractional LMUL is always occupy one vector register. Reviewed By: frasercrmck Differential Revision: https://reviews.llvm.org/D112599 -
Chuanqi Xu authored
I found that the coroutine intrinsic llvm.coro.param in documentation (https://llvm.org/docs/Coroutines.html#id101) didn't get used actually since there isn't lowering codes in LLVM. I also checked the implementation of libstdc++ and libc++. Both of them didn't use llvm.coro.param. So I am pretty sure that the llvm.coro.param intrinsic is unused. I think it would be better t to remove it to avoid possible misleading understandings. Note: according to [class.copy.elision]/p1.3, this optimization is allowed by the C++ language specification. Let's make it someday. Reviewed By: rjmccall Differential Revision: https://reviews.llvm.org/D115222
-
MaheshRavishankar authored
The region of `linalg.generic` might contain `tensor` operations. For example, current lowering of `gather` uses a `tensor.extract` in the body of the `LinalgOp`. Bufferize the ops within a `LinalgOp` region as well to catch such cases. Differential Revision: https://reviews.llvm.org/D115322
-
Dmitry Vyukov authored
Fork the current version of tsan runtime before commiting rewrite of the runtime (D112603). The old runtime can be enabled with TSAN_USE_OLD_RUNTIME option. This is a temporal measure for emergencies and is required for Chromium rollout (for context see http://crbug.com/1275581). The old runtime is supposed to be deleted soon. Reviewed By: thakis Differential Revision: https://reviews.llvm.org/D115223
-
Chuanqi Xu authored
Previously we would create global module fragment for extern linkage declaration which is alreday in global module fragment. However, it is clearly redundant to do so. This patch would check if the extern linkage declaration are already in GMF before we create a GMF for it.
-
Mircea Trofin authored
-
Mircea Trofin authored
-
Kazu Hirata authored
-
LLVM GN Syncbot authored
-
Mircea Trofin authored
This prepares it for the regalloc work. Part of it is making model evaluation accross 'development' and 'release' scenarios more reusable. This patch: - extends support to tensors of any shape (not just scalars, like we had in the inliner -Oz case). While the tensor shape can be anything, we assume row-major layout and expose the tensor as a buffer. - exposes the NoInferenceModelRunner, which we use in the 'development' mode to keep the evaluation code path consistent and simplify logging, as we'll want to reuse it in the regalloc case. Differential Revision: https://reviews.llvm.org/D115306
-
Zi Xuan Wu authored
Complete basic arithmetic operations such as add/sub/mul/div, and it also includes converions and some specific operations such as bswap.Add load/store patterns to generate different addressing mode instructions. Also enable some infra such as copy physical register and eliminate frame index.
-
Joe Loser authored
No tests are using `libcxx/test/support/tracked_value.h`. So, remove it. Differential Revision: https://reviews.llvm.org/D115411
-
Mircea Trofin authored
Renamed to conform to coding style
-
Noah Shutty authored
A [[ https://lists.llvm.org/pipermail/llvm-dev/2021-December/154203.html | report on llvm-dev ]] indicated that `curl.h` could be found during build configuration but not during compilation. This diff uses the libcurl imported library created by findcurl, so that includes and libs are automatically managed correctly by cmake. Reviewed By: phosek Differential Revision: https://reviews.llvm.org/D115189
-
Chen Zheng authored
Now we won't copy the byval parameter (bigger than 8 bytes) to caller's parameter save area. Instead, we will only copy the byval parameter when it can not be passed entirely in registers which means we have to use parameter save area according to the 64 bit SVR4 ABI. Reviewed By: jsji Differential Revision: https://reviews.llvm.org/D111485
-
Nico Weber authored
-
Andrew Browne authored
This reverts commit 5c277402. Reverting due to Windows build issue: sanitizer_stackdepot.cpp.obj : error LNK2005: "void __cdecl __sanitizer::StackDepotStopBackgroundThread(void)" (?StackDepotStopBackgroundThread@__sanitizer@@YAXXZ) already defined in sanitizer_common_libcdep.cpp.obj LINK : fatal error LNK1181: cannot open input file 'projects\compiler-rt\lib\asan\CMakeFiles\RTAsan_dynamic.x86_64.dir\asan_rtl_x86_64.S.obj'
-
Duncan P. N. Exon Smith authored
Stop using `SmallVector::set_size()` in zlib. Replace pairs of `reserve()` / `set_size()` with `resize_for_overwrite()` and `truncate()`. Differential Revision: https://reviews.llvm.org/D115391
-
Duncan P. N. Exon Smith authored
Stop using `SmallVector::set_size()` in sys::path APIs. In both cases, use `truncate()` instead. Differential Revision: https://reviews.llvm.org/D115391
-
Nico Weber authored
-
Siva Chandra Reddy authored
Generation of the .yaml has been removed to prevent lint from running with every ninja invocation. The new .clang-tidy file is copied to the libc build directory so that generated files also get checked. Reviewed By: michaelrj Differential Revision: https://reviews.llvm.org/D115405
-
Kirill Stoimenov authored
This reverts commit f71c553a. Reviewed By: kstoimenov Differential Revision: https://reviews.llvm.org/D115407
-
Duncan P. N. Exon Smith authored
This unblocks using `StringLiteral::size()` for a SmallVector size in another patch. Differential Revision: https://reviews.llvm.org/D115395
-
Nico Weber authored
-
Kirill Stoimenov authored
This change moves optimized callbacks from each .o file to compiler-rt. Instead of using code generation it uses direct assembly implementation. Please note that the 'or' version is not implemented and it will produce unresolved external if somehow 'or' version is requested. Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D114558
-
Matt Arsenault authored
This introduces verifier errors into this broken situation which we do not handle correctly, which is better than being silently miscompiled. For the emergency stack slot, the scavenger likes to move the restore instruction as late as possible, which ends up separating the SCC def from the conditional branch.
-
Matt Arsenault authored
Remove the control flow from the test from 25eb7fa0. It's not necessary to reproduce the original assert with the patch reverted. The control flow happens to expose a different issue that calls for a separate test in a future change.
-
Matt Arsenault authored
This improves liveness queries in a future change.
-
Craig Topper authored
The SMLoc::getFromPointer(S.getPointer() - 1) pattern used in several place didn't make sense since that puts the End before the Start location. This patch corrects this to properly calculate the end location as we parse. Unsure how much this matters, a lot of these are for custom operand parsing. If the custom parsing succeeds, the instruction matching probably won't fail, so the end loc won't be used to build a range for a diagnostic. I've also fixed the creation functions for the CSR and VType operands to assign the EndLoc of the RISCVOperand class using the StartLoc instead of an empty SMLoc. I don't think these will ever be accessed, but it makes the code look less like we forgot to assign it. This is consistent with some operands on the ARM target. Reviewed By: luismarques Differential Revision: https://reviews.llvm.org/D115192
-
Med Ismail Bennani authored
It can happen that a line entry reports that some source code is located at line 0. In DWARF, line 0 is a special location which indicates that code has no 1-1 mapping with source. When stopping in one of those artificial locations, lldb doesn't know which line to display and shows the beginning of the file instead. This patch mitigates this behaviour by checking if the current symbol context of the line entry has a matching function, in which case, it slides the source listing to the start of that function. This patch also shows the user a warning explaining why lldb couldn't show sources at that location. rdar://83118425 Differential Revision: https://reviews.llvm.org/D115313 Signed-off-by:
Med Ismail Bennani <medismail.bennani@gmail.com>
-
Duncan P. N. Exon Smith authored
Update `OpenMPIRBuilder::collapseLoops()` to call `resize()` instead of `set_size()`. The latter asserts on capacity limits and cannot grow, which seems likely to be unintentional here (if it is, I think a local assertion would be good for clarity). Also update `CodeGenFunction::EmitOMPCollapsedCanonicalLoopNest()` to use `pop_back_n()` instead of `set_size()`. Differential Revision: https://reviews.llvm.org/D115378
-
Jonas Devlieghere authored
Because of its dependency on clang (and potentially other compilers downstream, such as swift) lldb_private::GetVersion already lives in its own library called lldbBase. Despite that, its implementation was spread across unrelated files. This patch improves things by introducing a Version library with its own directory, header and implementation file. The benefits of this patch include: - We can get rid of the ugly quoting macros. - Other parts of LLDB can read the version number from lldb/Version/Version.inc. - The implementation can be swapped out for tools like lldb-server than don't need to depend on clang at all. Differential revision: https://reviews.llvm.org/D115211
-
Carlo Bertolli authored
Prepare amdgpu plugin for asynchronous implementation. This patch switches to using HSA API for asynchronous memory copy. Moving away from hsa_memory_copy means that plugin is responsible for locking/unlocking host memory pointers. Reviewed By: JonChesterfield Differential Revision: https://reviews.llvm.org/D115279
-
Taewook Oh authored
This diff adds "dfsan-ignore-personality-routine" flag, which makes the dfsan pass to not to generate wrappers for the personality functions if the function is marked uninstrumented. This flag is to support dfsan with the cases where the exception handling routines cannot be instrumented (e.g. use the prebuilt version of c++ standard library). When the personality function cannot be instrumented it is supposed to be marked "uninstrumented" from the abi list file. While DFSan generates a wrapper function for uninstrumented functions, it cannot cannot generate a valid wrapper for vararg functions, and indirect invocation of vararg function wrapper terminates the execution of dfsan-instrumented programs. This makes invocation of personality routine to crash the program, because 1) clang adds a declaration of personality functions as a vararg function with no fixed argument, and 2) personality routines are always called indirectly. To address this issue, the flag introduced in this diff makes dfsan to not to instrument the personality function. This is not the "correct" solution in the sense that return value label from the personality function will be undefined. However, in practice, if the exception handling routines are uninstrumented we wouldn't expect precise label propagation around them, and it would be more beneficial to make the rest of the program run without termination. Reviewed By: browneee Differential Revision: https://reviews.llvm.org/D115317
-
Rob Suderman authored
Count leading/trailing zeros are an existing LLVM intrinsic. Added LLVM support for the intrinsics with lowerings from the math dialect to LLVM dialect. Reviewed By: ftynse Differential Revision: https://reviews.llvm.org/D115206
-
wlei authored
-
Arthur Eubanks authored
This reverts commit f9235e45. Causes breakages on Windows: http://45.33.8.238/win/50453/step_11.txt.
-
Duncan P. N. Exon Smith authored
Add `SmallVectorImpl::truncate()`, a variant of `resize()` that cannot increase the size. - Compared to `resize()`, this has no code path for growing the allocation and can be better optimized. - Compared to `set_size()`, this formally calls destructors, and does not skip any constructors. - Compared to `pop_back_n()`, this takes the new desired size, which in many contexts is more intuitive than the number of elements to remove. The immediate motivation is to pair this with `resize_for_overwrite()` to remove uses of `set_size()`, which can then be made private. Differential Revision: https://reviews.llvm.org/D115383
-
Anna Thomas authored
Add inferable writeonly attribute. Simplify testcase.
-