[Hexagon] Fix reg class for C2_cmoveit/cmoveif cext lowering (#212911)
HexagonConstExtenders::getDirectRegReplacement mapped C2_cmoveit and
C2_cmoveif (32-bit predicated immediate moves into IntRegs) to A2_tfrpt
/ A2_tfrpf - the 64-bit DoubleRegs predicated transfers. When the
const-extender pass found a shared extended immediate profitable to
hoist into a register, it rewrote
%d:intregs = C2_cmoveit %p:predregs, #imm
into
%d:intregs = A2_tfrpt %p:predregs, %hoisted:intregs (BAD)
producing a paired-register transfer with IntRegs operands and tripping
the machine verifier:
Bad machine code: Illegal virtual register for instruction
Expected a DoubleRegs register, but got a IntRegs register
[9 lines not shown]
[SandboxVec][SeedCollector] Fix seed insert if can't determine mem access distance (#213807)
Up until now we would insert a memory instruction in a MemSeedBundle
even if we could not determine the access distance against the existing
bundle instructionss. This was causing a crash in the invocation of
upper_bound() as the vector could no longer be partitioned.
The fix is to extend the functions that check the memory access ordering
to return nullopt when the access difference can't be determined.
[lldb] Use StringRef when creating Listeners (#214863)
This is primarily motivated to remove the last ConstString from
Debugger.cpp. It would have been possible to write this change without
changing Listener, but then I noticed a few places where we would have
benefitted from changing the interface.
[docs] Finish MyST migration for selected LLVM docs (#214618)
Tracking issue: #201242
See the [migration guide] for more information.
[migration guide]:
https://llvm.org/docs/SphinxQuickstartTemplate.html#markdown-migration-guidelines
This is a stacked PR based on #214616 , which will be a standalone
commit that
renames *.rst -> *.md before this PR lands for history preservation
purposes.
This was prepared with rst2myst plus LLM-assisted cleanup. I paged
through all the generated HTML looking for migration artifacts, and all
of the differences I could find appear to be formatting error
corrections.
[docs] Rename selected LLVM docs to Markdown (#214616)
Tracking issue: #201242
See the [migration guide] for more information.
[migration guide]:
https://llvm.org/docs/SphinxQuickstartTemplate.html#markdown-migration-guidelines
This is the initial straight rename commit. It will probably break the
docs build, but it has to be a separate PR for blame preservation
purposes.
[CIR] Route MLIR diagnostics through clang::DiagnosticsEngine (#199297)
Install a scoped MLIR diagnostic handler on the CIRGenerator's
MLIRContext that translates mlir::Diagnostic severity and location to
clang diag IDs and SourceLocation, so CIR pass / verifier / lowering
errors surface in clang's standard format and respect -W/-R flags.
Disable MLIR multithreading on that context (DiagnosticsEngine is not
thread-safe). Gate the generic CIR-to-CIR fallback errors on
hasErrorOccurred() to avoid double-printing alongside specific routed
diagnostics.
[OpenACC] Don't generate a call to emitStmt if we don't have one. (#215387)
OpenACC assumed that the statement it got when parsing the associated
statement would either be an error or a valid statement. However, there
are some cases where a statement does nothing where we don't bother to
generate a statement object at all. This patch makes the OpenACC codegen
tolerant of that.
Fixes: #215246
[Flang][OpenMP] Generate maps for allocatable components of privatized symbols for target offload (#214015)
Currently we do not generate maps for allocatable components of derived
types for privatized derived type symbols, this can be a problem when
the variable requires initialization from the original copy, as the
device will try to perform initialization and the data will not be
present to do so. This causes a runtime memory access error on device.
Some example code that can trigger this:
type :: btype
real(kind=8),allocatable, dimension(:) :: a
end type
!$omp target teams distribute parallel do firstprivate(b)
This does not apply to pointers as they aren't mandated to be
initialized as allocatables are at the moment I believe when they're
sub-objects. But it does apply to allocatables where initialization and
copy blocks are generated.
[4 lines not shown]
[flang][AIX] Diagnose unsupported OBJECT_MODE setting and -maix32 option (#209919)
This patch is to align flang's default behavior to the other tools in
toolchain on AIX. Flang assumes 32-bit compile by default. The compile
mode can be overridden by setting environment variable OBJECT_MODE=64 or
specifying the -maix64 option.
[CIR] Change the 'inline_kind' enum to have an explicit attribute (#215335)
If we use the builtin automatic inline-kind here, we don't get to have
it printed reasonably/normally. This patch adds the
'genSpecializedAttr=0' and adds an explicit attribute so we print it as
an enum value.
[SandboxVec][Scheduler] Fix false negatives (#211108)
This patch fixes an issue where trySchedule() could return false even
though scheduling was legal. This would happen after a failed
trySchedule(Bndl1) attempt for a bundle that would span a large number
of instructions. Any subsequent trySchedule(Bndl2) for a bundle that
would span fewer instrs than Bndl1 would return false because the
scheduler would not scan the required instructions to add them to the
ready list.
[NVPTX] Make `shortptr` a target ABI (#214112)
Refactor our handling of `shortptr` to make it a proper target ABI
instead of plumbing it through with CLI options.
Assisted by AI.
[clang][OpenMP] Split OMPOrderedDirective into two classes
Now that OMPD_ordered has been replaced with two variants, split
the OMPOrderedDirective class into two classes, one for each
variant.