[mlir][sparse_tensor] Fix out-of-bounds read in SparseAssembleOpConverter (#203289)
The assemble codegen loop iterates over the level rank but asserted on
`getDimShape()[lvl]`, which is sized by the dimension rank. Index the
level shape instead, matching the loop bound and the next line.
Fixes #203225.
[MLIR][SparseTensor] Added Sparse Outer Loop Ordering Strategy (#172198)
This PR builds upon the infrastructure set up for Sparse Tensor Loop
Ordering Heuristics (#154656) and the already existing Dense Outer loop
ordering strategy (#160168).
[llvm-cov] Add inline exclusion marker support for coverage reporting
Add --exclude-line-regex, --exclude-region-start-regex, and
--exclude-region-stop-regex options to llvm-cov. These allow excluding
lines from coverage totals based on inline source comments.
Defaults: LCOV_EXCL_LINE (single line), LCOV_EXCL_START/LCOV_EXCL_STOP
(region). This brings parity with lcov/gcov exclusion markers and
kcov --exclude-line regex support.
The implementation scans source files for markers when loaded, builds a
per-file set of excluded line numbers, and subtracts them from the line
coverage totals in prepareFileReports().
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply at anthropic.com>
[llvm-cov] Add inline exclusion marker support for coverage reporting
Add --exclude-line-regex, --exclude-region-start-regex, and
--exclude-region-stop-regex options to llvm-cov. These allow excluding
lines from coverage totals based on inline source comments.
Defaults: LCOV_EXCL_LINE (single line), LCOV_EXCL_START/LCOV_EXCL_STOP
(region). This brings parity with lcov/gcov exclusion markers and
kcov --exclude-line regex support.
The implementation scans source files for markers when loaded, builds a
per-file set of excluded line numbers, and subtracts them from the line
coverage totals in prepareFileReports().
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply at anthropic.com>
[llvm-cov] Add inline exclusion marker support for coverage reporting
Add --exclude-line-regex, --exclude-region-start-regex, and
--exclude-region-stop-regex options to llvm-cov. These allow excluding
lines from coverage totals based on inline source comments.
Defaults: LCOV_EXCL_LINE (single line), LCOV_EXCL_START/LCOV_EXCL_STOP
(region). This brings parity with lcov/gcov exclusion markers and
kcov --exclude-line regex support.
The implementation scans source files for markers when loaded, builds a
per-file set of excluded line numbers, and subtracts them from the line
coverage totals in prepareFileReports().
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply at anthropic.com>
[llvm-cov] Add inline exclusion marker support for coverage reporting
Add --exclude-line-regex, --exclude-region-start-regex, and
--exclude-region-stop-regex options to llvm-cov. These allow excluding
lines from coverage totals based on inline source comments.
Defaults: LCOV_EXCL_LINE (single line), LCOV_EXCL_START/LCOV_EXCL_STOP
(region). This brings parity with lcov/gcov exclusion markers and
kcov --exclude-line regex support.
The implementation scans source files for markers when loaded, builds a
per-file set of excluded line numbers, and subtracts them from the line
coverage totals in prepareFileReports().
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply at anthropic.com>
[LV] Allow AddChainWithSubs in ExtNegatedMulAccReduction. (#203720)
For chained reductions identified as RecurKind::AddChainWithSubs, VPlan
construction rewrites each sub link as 0 - X so that the in-loop
reduction can treat the chain uniformly as a sum. The
ExtNegatedMulAccReduction VPExpressionRecipe matches that 0 - mul form,
but its constructor only allowed RecurKind::Add and asserted otherwise,
crashing with -prefer-inloop-reductions on the added tests.
AddChainWithSubs maps to Instruction::Add via
RecurrenceDescriptor::getOpcode, so the rest of the recipe (cost
computation, codegen) already handles it. Relax the constructor assert
to also accept AddChainWithSubs.
[llvm-cov] Add inline exclusion marker support for coverage reporting
Add --exclude-line-regex, --exclude-region-start-regex, and
--exclude-region-stop-regex options to llvm-cov. These allow excluding
lines from coverage totals based on inline source comments.
Defaults: LCOV_EXCL_LINE (single line), LCOV_EXCL_START/LCOV_EXCL_STOP
(region). This brings parity with lcov/gcov exclusion markers and
kcov --exclude-line regex support.
The implementation scans source files for markers when loaded, builds a
per-file set of excluded line numbers, and subtracts them from the line
coverage totals in prepareFileReports().
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply at anthropic.com>
[llvm-cov] Add inline exclusion marker support for coverage reporting
Add --exclude-line-regex, --exclude-region-start-regex, and
--exclude-region-stop-regex options to llvm-cov. These allow excluding
lines from coverage totals based on inline source comments.
Defaults: LCOV_EXCL_LINE (single line), LCOV_EXCL_START/LCOV_EXCL_STOP
(region). This brings parity with lcov/gcov exclusion markers and
kcov --exclude-line regex support.
The implementation scans source files for markers when loaded, builds a
per-file set of excluded line numbers, and subtracts them from the line
coverage totals in prepareFileReports().
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply at anthropic.com>
[HLSL] Disable implicit constructors for user-defined structs/classes (#194989)
Disables implicit constructors and assignment operators on user-defined
structs/classes in HLSL.
When a struct is copied or passed as an argument to a function, instead
of using copy constructor the compiler inserts an implicit
_lvalue_-to-_rvalue_ cast where necessary to copy the value. In C++
these implicit casts are not allowed. Sema initialization and
overloading code has been adjusted to enable this code path for HLSL.
For struct in a constant buffer, the implicit cast changes the constant
address space to the default one. Codegen recognized this pattern and
instead of translating the copy as `memcpy`, it copies the struct
element-by-element (because the constant address space struct can have a
different layout).
To efficiently recognize whether a `CXXRecordDecl` is a user-defined
struct/class or if it is an HLSL built-in struct/class, a new bit
[5 lines not shown]
[VPlan] Run final removeBranchOnConst after late simplifyRecipes. (#193069)
simplifyRecipes may expose additional known branches. Move final
removeBranchOnConst after the late simplifyRecipes run.
Removing branches like the vector loop backedge leads to additional
simplifications, like removing trivial phis etc. Return true if any phis
have incoming values have been removed by removeBranchOnConst. If so, we
need another simplifyRecipes run.
Depends on https://github.com/llvm/llvm-project/pull/193067 for
functional changes.
PR: https://github.com/llvm/llvm-project/pull/193069
[Test] Fix LSR tests to prevent trivial simplification of icmp (#203705)
Replace undef operands in funclet.ll with function parameters and adjust
the loop bound in reuse-existing-phi.ll so the new simplification pass
does not fold away the comparisons these tests are meant to exercise.
[libcxx] Do not mark mkstemp tests xfail for libc (#203681)
mkstemp was recently implemented in
c9b25a6437fd97fdb1e55ab6661c0cccce98913e, so these tests now pass.
[clang-tidy] Avoid non-const-parameter fix-it conflicts with overloads (#202490)
`readability-non-const-parameter` can suggest changing `T *` to `const T
*` when that would conflict with an existing overload. Suppress the
diagnostic in that case by comparing the post-fix parameter list against
other declarations with the same name.
Closes https://github.com/llvm/llvm-project/issues/202478
[OpenACC] Fix scope setup for OpenACC directives without scope. (#203687)
When implementing these, I intended to have the 'empty' parse scopes for
most of the directives introduced for simplicity. However some
assertions show that this is not a valid use of this, as it doesn't
tolerate 'empty' parse scopes. This patch stops introducing one.
Fixes: #203679