[DWARFLinker] Support parseable Swift interfaces in the parallel linker (#195475)
CompileUnit::Language was filtered through isODRLanguage at construction,
so non-ODR languages landed as std::nullopt and analyzeImportedModule's
Swift branch was never reached under --linker parallel. Store the raw
DW_AT_language and apply isODRLanguage only where ODR is actually
decided.
Reaching that branch then exposes a shared-map write from
parallelForEach workers. A mutex would make it safe but not
deterministic: conflict warnings and last-writer-wins contents would
depend on thread scheduling and diverge from the classic linker. Stage
entries per-CU and merge them serially in input order after analysis, so
results match classic regardless of schedule.
Because the diagnostics are emitted after unloading the input, we do
lose the originating DW_TAG_module. The warning still names the module
and both conflicting paths, which carries the load-bearing information.
ipsec: fancy up the connections dialog
It's a bit special but save is for the form in particular
and this way we can have native striping. The grids save
on their own and hopefully UI will be clearer now.
Add a static header option for it and fix true/false checks.
Close the extra dialog-form on apply.
Discussed with: @Monviech
ipsec: reduce visual jumping on page by reusing grids
only hide if we're coming from a different tab. Any change
triggered on the tab itself will now clear the grids and reload
them so the content doesn't pop out and in of existence when
pressing save.
As a fallback, always hide if the connection doesn't exist
[ELF] Support non-section Defined symbols at MergeInputSection end (#195801)
Commit bb443359a8ad ("[ELF] Validate merge section offsets in getSymVA
and
match GNU ld") accepts offset == section_size for section-symbol
references
in getSymVA, and skips the out-of-bounds case in MarkLive.
This patch extends the support for non-section Defined symbols,
modifying the per-symbol pre-resolution added by commit 42cc45477727
("[ELF] Optimize binary search in getSectionPiece").
Fix #118148
[DWARFLinker] Patch DW_AT_LLVM_stmt_sequence in the parallel linker (#195388)
Mirror dsymutil's stmt-sequence rewriting in the parallel linker so each
attribute ends up pointing at the DW_LNE_set_address that opens its
containing output sequence, with the correct offset in the combined
.debug_line.
At DIE cloning time we resolve each attribute's input offset to the
address of its first row and record the pair (DIEValue, address) on the
CompileUnit, alongside a DebugOffsetPatch on the .debug_info section so
combination adds the CU's .debug_line start offset. The line-table
emitter then fills a map from row address to the byte offset of the
sequence-opening DW_LNE_set_address.
After emission, each recorded attribute is rewritten by relocating its
input address through the CU's function ranges and looking the result up
in the map. When resolution fails the DWARF max-offset sentinel is
written instead, and the patch applier preserves it unchanged.
First-row lookups share a lazy per-CU cache to keep resolution O(1) per
attribute.
Reland [Inliner] Use store-to-load forwarding to resolve call arguments (#195526)
Adds store to load forwarding when inliner has successfully done some
inlining. This allows simplification of further inlining attempts and
can give them more precise cost analysis.
It allows to optimize away empty `std::set` and `std::map` in both
`libc++` and `libstdc++` and many other real world cases.
Reland of #190607. It was reverted since it was causing crashes in
#195135. These were crashes in `FindAvailableLoadedValue` on mixed
address space pointers and should be fixed by #195256
Revert "libusb: change callback register handler to int"
This reverts commit ce9ced951a0b9d004a3b007d4ac6e9087a1301a2.
We should handle backward compatibility before introducing this patch as
people may rely on old ABI.
[HLSL] For builtins aliases, apply implicit conversions before running custom type checking (#195365)
Fixes https://github.com/llvm/llvm-project/issues/195329 by making HLSL
builtin aliases apply implicit conversions before running custom type
checking.
After this PR:
- There are no more size 1 vectors being passed and returned to/from
aliased Clang builtins because they get truncated to scalars due to the
HLSL alias builtin not having explicit size 1 vector overloads.
- HLSL alias builtins no longer accept matrices unless they have
explicit matrix overloads. Matrices get implicitly truncated to scalars
and resolve to the scalar Clang builtin being aliased.
- Many calls with mismatched vector sizes no longer error with
`arguments are of different types` and instead follow Clang's overload
resolution rules with respect to HLSL's implicit conversion sequences.
(e.g., `dot(float3, float2)` -> `dot(float2, float2)` with warning)
- Calls with implicitly-convertible types no longer error. They are now
implicitly converted, and with a warning in some cases. (e.g.,
[3 lines not shown]
[VPlan] Scalarize to first-lane-only directly on VPlan (#184267)
This is needed to enable subsequent
https://github.com/llvm/llvm-project/pull/182595.
I don't think we can fully port all scalarization logic from the legacy
path to VPlan-based right now because by that point in the pipeline
interleave groups aren't lowered into any VPlan-based representation and
as such this pass operates on incomplete information. Currently, the
pass can make transformations if "all uses are scalar" (that won't
change later) but not "are uses a mix of vector and scalar uses" (that
might change after lowering interleave groups).
As such, I decided just to implement something much simpler that would
be enough for #182595. However, we perform this transformation before
delegating to the old CM-based decision, so it **is** effective
immediately and taking precedence even for consecutive loads/stores
right away.
[2 lines not shown]