- Jan 05, 2022
-
-
Bharadwaj, Ritanya B authored
This is a segmentation fault in INTERCEPTOR function on a special edge case of strstr libc call. When 'Haystack'(main string to be examined) is NULL and 'needle'(sub-string to be searched in 'Haystack') is an empty string then it hits a SEGV while using sanitizers and as a 'string not found' case otherwise. Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D115919
-
serge-sans-paille authored
Differential Revision: https://reviews.llvm.org/D116598
-
Nikolas Klauser authored
Remove duplicate header includes from `<algorithm>` and reorder the includes Reviewed By: Quuxplusone, ldionne, Mordante, #libc, jloser Spies: jloser, libcxx-commits Differential Revision: https://reviews.llvm.org/D116507
-
Zi Xuan Wu authored
-
Zi Xuan Wu authored
Add basic integer codegen of select/br/cmp instruction. It also includes frame lowering code such as prologue/epilogue.
-
Jim Lin authored
-
Mikael Holmen authored
-
Shao-Ce SUN authored
-
Florian Mayer authored
Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D116639
-
Mehdi Amini authored
Each attribute has two accessor: one suffixed with `Attr` which returns the attribute itself and one without the suffix which unwrap the attribute. For example for a StringAttr attribute with a field named `kind`, we'll generate: StringAttr getKindAttr(); StringRef getKind(); Differential Revision: https://reviews.llvm.org/D116466
-
Xu Mingjie authored
In https://reviews.llvm.org/D86905, we introduce an optimization, when lld emits LLVM bitcode, we allow bitcode writer flush data to disk early when buffered data size is above some threshold. But when `--plugin-opt=emit-llvm` and `-o /dev/null` are used, lld will trigger assertion `BytesRead >= 0 && static_cast<size_t>(BytesRead) == BytesFromDisk`. When we write output to /dev/null, BytesRead is zero, but at this program point BytesFromDisk is always non-zero. Reviewed By: stephan.yichao.zhao, MaskRay Differential Revision: https://reviews.llvm.org/D112297
-
Pravin Jagtap authored
Differential Revision: https://reviews.llvm.org/D116641
-
Mircea Trofin authored
-
Chuanqi Xu authored
We could use the variable as a flag to indicate if the optimization is on.
-
Fangrui Song authored
-
Luís Ferreira authored
LLVM core library supports demangling other mangled symbols other than itanium, such as D and Rust. LLD should use those demanglers in order to output pretty demangled symbols on error messages. Reviewed By: MaskRay, #lld-macho Differential Revision: https://reviews.llvm.org/D116279
-
Fangrui Song authored
D116426 may lead to an assertion failure `Attributes 'readonly and writeonly' are incompatible!` if the builtin function already has `readonly`.
-
Chuanqi Xu authored
This fixes bug49264. Simply, coroutine shouldn't be inlined before CoroSplit. And the marker for pre-splited coroutine is created in CoroEarly pass, which ran after AlwaysInliner Pass in O0 pipeline. So that the AlwaysInliner couldn't detect it shouldn't inline a coroutine. So here is the error. This patch set the presplit attribute in clang and mlir. So the inliner would always detect the attribute before splitting. Reviewed By: rjmccall, ezhulenev Differential Revision: https://reviews.llvm.org/D115790
-
Heejin Ahn authored
This uses `changeToCall` and `changeToInvokeAndSplitBasicBlock` from `lib/Transforms/Utils`, replacing the custom logic. One difference of those functions from our previous logic is they delete the original `CallInst`/`InvokeInst`, which makes them tricky to use while iterating through instructions/BBs. So this CL gathers the candidate calls first and run them through `changeToInvokeAndSplitBasicBlock` later. Also this renames some variables. Reviewed By: dschuff Differential Revision: https://reviews.llvm.org/D116620
-
Heejin Ahn authored
D107530 did a small optimization that, if a function contains `setjmp` calls but not other calls that can `longjmp`, we don't do SjLj transformation on those `setjmp` calls, because they don't have possibilities of returning from `longjmp`. But we should remove those `setjmp` calls even in that case, because Emscripten doesn't provide that function, assuming it is lowered away by SjLj transformation. `setjmp` always returns 0 when called directly, so this CL replaces them with `i32 0`. Fixes https://github.com/emscripten-core/emscripten/issues/15679. Reviewed By: dschuff Differential Revision: https://reviews.llvm.org/D116619
-
Fangrui Song authored
-
Rumeet Dhindsa authored
This reverts commit dd72ae3d. Notified the author of the internal failure and author suggested to revert it for now.
-
wren romano authored
Depends On D115010 This changes a couple of places that used to `return failure();` to now use `llvm_unreachable()` instead. However, `Transforms/Sparsification.cpp` should be doing the necessary type checks to ensure that those cases are in fact unreachable. Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D115012
-
wren romano authored
Depends On D115008 This change opens the way for D115012, and removes some corner cases in `CodegenUtils.cpp`. The `SparseTensorAttrDefs.td` already specifies that we allow `0` bitwidth for the two overhead types and that it is interpreted to mean the architecture's native width. Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D115010
-
wren romano authored
This moves a bunch of helper functions from `Transforms/SparseTensorConversion.cpp` into `Transforms/CodegenUtils.{cpp,h}` so that they can be reused by `Transforms/Sparsification.cpp`, etc. See also the dependent D115010 which cleans up some corner cases in this change. Reviewed By: aartbik, rriddle Differential Revision: https://reviews.llvm.org/D115008
-
Henry Linjamäki authored
Consider case where `__int128` type is supported by the host target but not by a device target (e.g. spirv*). Clang emits an error message for unsupported type even if the device code does not use it. This patch fixes this issue by emitting the error message when the device code attempts to use the unsupported type. Reviewed By: tra Differential Revision: https://reviews.llvm.org/D111047
-
Sumanth Gundapaneni authored
Ideally we should make USR as Def for these floating point instructions. However, it violates some assembler MCChecker rules. This patch fixes the issue by marking these FP instructions as non-sinkable.
-
SANTANU DAS authored
This patch aids to reduce code size since it removes generation of back-to-back A2_tfrsi instructions. It is enabled only at -Os/-Oz.
-
Krzysztof Parzyszek authored
-
Jacques Pienaar authored
If a fusedloc is created with a single location then no fusedloc was previously created and single location returned instead. In the case where there is a metadata associated with the location this results in discarding the metadata. Instead only canonicalize where there is no loss of information. Differential Revision: https://reviews.llvm.org/D115605
-
Fangrui Song authored
Similar to ELF 3a5fb573. * previously when a LazyObjFile was extracted, a new ObjFile/BitcodeFile was created; now the file is reused, just with `lazy` cleared * avoid the confusing transfer of `symbols` from LazyObjFile to the new file * simpler code, smaller executable (5200+ bytes smaller on x86-64) * make eager parsing feasible (for parallel section/symbol table initialization) Reviewed By: aganea, rnk Differential Revision: https://reviews.llvm.org/D116434
-
- Jan 04, 2022
-
-
Nikolas Klauser authored
-
LLVM GN Syncbot authored
-
Nikolas Klauser authored
Add `indirectly_comparable` concept Reviewed By: Quuxplusone, Mordante, #libc Spies: mgorny, libcxx-commits Differential Revision: https://reviews.llvm.org/D116268
-
Brendon Cahoon authored
-
V Donaldson authored
F18 constraint C1308 is: For the G edit descriptor, e shall not be specified if w is zero. For an edit descriptor such as 'G0.2E4', change the error message from: error: Unexpected 'e' in 'G0' edit descriptor To: error: A 'G0' edit descriptor must not have an 'e' value
-
Arthur O'Dwyer authored
`__cpp_lib_type_identity` was implemented way back in cf49ccd0 (Clang 8), probably before the feature-test macro had been settled on. `__cpp_lib_string_resize_and_overwrite` will be added by D113013 so I didn't add it here. Fixes #46605. Differential Revision: https://reviews.llvm.org/D116433
-
Arthur O'Dwyer authored
For example, `std::ranges::range<Holder<Incomplete>*>` should be well-formed false, not a hard error at compile time. Differential Revision: https://reviews.llvm.org/D116239
-
Arthur O'Dwyer authored
Reviewed as part of D116239.
-
Harsha Jagasia authored
For code below: { r7 = addasl(r3,r0,#2) r8 = addasl(r3,r2,#2) r5 = memw(r3+r0<<#2) r6 = memw(r3+r2<<#2) } { p1 = cmp.gtu(r6,r5) if (p1.new) memw(r8+#0) = r5 if (p1.new) memw(r7+#0) = r6 } { r0 = mux(p1,r2,r4) } In packetizer, a new packet is created for the cmp instruction since there arent enough resources in previous packet. Also it is determined that the cmp stalls by 2 cycles since it depends on the prior load of r5. In current packetizer implementation, the predicated store is evaluated for whether it can go in the same packet as compare, and since the compare stalls, the stall of the predicated store does not matter and it can go in the same packet as the cmp. However the predicated store will stall for more cycles because of its dependence on the addasl instruction and to avoid that stall we can put it in a new packet. Improve the packetizer to check if an instruction being added to packet will stall longer than instruction already in packet and if so create a new packet.
-