Skip to content

Commit 27c034a

Browse files
authored
[Hexagon] Fix typos discovered by codespell (NFC) (#126233)
Found using https://github.com/codespell-project/codespell ``` codespell Hexagon --write-changes \ --ignore-words-list=CarryIn,CreateOr,ORE,COPYs,ArchVer,predicable,UE,MIs,isNT,Vor,CountR,DUM,GEs,AddD,ToI, \ CopyIn,TheI,TotalIn,vor,MOne,contigious,Contigious ```
1 parent 9d134f2 commit 27c034a

27 files changed

+56
-55
lines changed

llvm/lib/Target/Hexagon/AsmParser/HexagonAsmParser.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ static cl::opt<bool> WarnSignedMismatch(
7474
cl::init(false));
7575
static cl::opt<bool> WarnNoncontigiousRegister(
7676
"mwarn-noncontigious-register",
77-
cl::desc("Warn for register names that arent contigious"), cl::init(true));
77+
cl::desc("Warn for register names that aren't contigious"), cl::init(true));
7878
static cl::opt<bool> ErrorNoncontigiousRegister(
7979
"merror-noncontigious-register",
8080
cl::desc("Error for register names that aren't contigious"),
@@ -1330,7 +1330,7 @@ unsigned HexagonAsmParser::validateTargetOperandClass(MCParsedAsmOperand &AsmOp,
13301330
return Match_InvalidOperand;
13311331
}
13321332

1333-
// FIXME: Calls to OutOfRange shoudl propagate failure up to parseStatement.
1333+
// FIXME: Calls to OutOfRange should propagate failure up to parseStatement.
13341334
bool HexagonAsmParser::OutOfRange(SMLoc IDLoc, long long Val, long long Max) {
13351335
std::string errStr;
13361336
raw_string_ostream ES(errStr);

llvm/lib/Target/Hexagon/HexagonBitSimplify.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2854,7 +2854,7 @@ bool HexagonBitSimplify::runOnMachineFunction(MachineFunction &MF) {
28542854
// Recognize loops where the code at the end of the loop matches the code
28552855
// before the entry of the loop, and the matching code is such that is can
28562856
// be simplified. This pass relies on the bit simplification above and only
2857-
// prepares code in a way that can be handled by the bit simplifcation.
2857+
// prepares code in a way that can be handled by the bit simplification.
28582858
//
28592859
// This is the motivating testcase (and explanation):
28602860
//

llvm/lib/Target/Hexagon/HexagonConstExtenders.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1040,7 +1040,7 @@ unsigned HCE::getDirectRegReplacement(unsigned ExtOpc) const {
10401040
// extender. It may be possible for MI to be tweaked to work for a register
10411041
// defined with a slightly different value. For example
10421042
// ... = L2_loadrub_io Rb, 1
1043-
// can be modifed to be
1043+
// can be modified to be
10441044
// ... = L2_loadrub_io Rb', 0
10451045
// if Rb' = Rb+1.
10461046
// The range for Rb would be [Min+1, Max+1], where [Min, Max] is a range

llvm/lib/Target/Hexagon/HexagonConstPropagation.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ namespace {
101101

102102
// Lattice cell, based on that was described in the W-Z paper on constant
103103
// propagation.
104-
// Latice cell will be allowed to hold multiple constant values. While
104+
// Lattice cell will be allowed to hold multiple constant values. While
105105
// multiple values would normally indicate "bottom", we can still derive
106106
// some useful information from them. For example, comparison X > 0
107107
// could be folded if all the values in the cell associated with X are
@@ -795,7 +795,7 @@ void MachineConstPropagator::visitUsesOf(unsigned Reg) {
795795
LLVM_DEBUG(dbgs() << "Visiting uses of " << printReg(Reg, &MCE.TRI)
796796
<< Cells.get(Reg) << '\n');
797797
for (MachineInstr &MI : MRI->use_nodbg_instructions(Reg)) {
798-
// Do not process non-executable instructions. They can become exceutable
798+
// Do not process non-executable instructions. They can become executable
799799
// later (via a flow-edge in the work queue). In such case, the instruc-
800800
// tion will be visited at that time.
801801
if (!InstrExec.count(&MI))

llvm/lib/Target/Hexagon/HexagonCopyToCombine.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ bool HexagonCopyToCombine::isSafeToMoveTogether(MachineInstr &I1,
385385
return true;
386386
}
387387

388-
/// findPotentialNewifiableTFRs - Finds tranfers that feed stores that could be
388+
/// findPotentialNewifiableTFRs - Finds transfers that feed stores that could be
389389
/// newified. (A use of a 64 bit register define can not be newified)
390390
void
391391
HexagonCopyToCombine::findPotentialNewifiableTFRs(MachineBasicBlock &BB) {

llvm/lib/Target/Hexagon/HexagonExpandCondsets.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -720,7 +720,7 @@ bool HexagonExpandCondsets::split(MachineInstr &MI,
720720
}
721721
}
722722

723-
// First, create the two invididual conditional transfers, and add each
723+
// First, create the two individual conditional transfers, and add each
724724
// of them to the live intervals information. Do that first and then remove
725725
// the old instruction from live intervals.
726726
MachineInstr *TfrT =

llvm/lib/Target/Hexagon/HexagonHardwareLoops.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -825,7 +825,7 @@ CountValue *HexagonHardwareLoops::computeCount(MachineLoop *Loop,
825825
// a computation of it into the preheader.
826826

827827
// If the induction variable bump is not a power of 2, quit.
828-
// Othwerise we'd need a general integer division.
828+
// Otherwise we'd need a general integer division.
829829
if (!isPowerOf2_64(std::abs(IVBump)))
830830
return nullptr;
831831

@@ -1398,10 +1398,10 @@ bool HexagonHardwareLoops::phiMayWrapOrUnderflow(
13981398
/// counter if it is <= 1. We only need to perform this analysis if the
13991399
/// initial value is a register.
14001400
///
1401-
/// This function assumes the initial value may underfow unless proven
1401+
/// This function assumes the initial value may underflow unless proven
14021402
/// otherwise. If the type is signed, then we don't care because signed
14031403
/// underflow is undefined. We attempt to prove the initial value is not
1404-
/// zero by perfoming a crude analysis of the loop counter. This function
1404+
/// zero by performing a crude analysis of the loop counter. This function
14051405
/// checks if the initial value is used in any comparison prior to the loop
14061406
/// and, if so, assumes the comparison is a range check. This is inexact,
14071407
/// but will catch the simple cases.

llvm/lib/Target/Hexagon/HexagonISelDAGToDAGHVX.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1984,7 +1984,7 @@ SmallVector<uint32_t, 8> HvxSelector::getPerfectCompletions(ShuffleMask SM,
19841984
// same as in P. This implies that P == Q.
19851985

19861986
// There can be a situation where there are more entries with the same
1987-
// bits set than there are set bits (e.g. value 9 occuring more than 2
1987+
// bits set than there are set bits (e.g. value 9 occurring more than 2
19881988
// times). In such cases it will be impossible to complete this to a
19891989
// perfect shuffle.
19901990
SmallVector<uint32_t, 8> Sorted(Worklist);
@@ -1995,7 +1995,7 @@ SmallVector<uint32_t, 8> HvxSelector::getPerfectCompletions(ShuffleMask SM,
19951995
while (++I != E && P == Sorted[I])
19961996
++Count;
19971997
if ((unsigned)llvm::popcount(P) < Count) {
1998-
// Reset all occurences of P, if there are more occurrences of P
1998+
// Reset all occurrences of P, if there are more occurrences of P
19991999
// than there are bits in P.
20002000
llvm::replace(Worklist, P, 0U);
20012001
}
@@ -2223,7 +2223,7 @@ OpRef HvxSelector::perfect(ShuffleMask SM, OpRef Va, ResultStack &Results) {
22232223
// V6_vdeal{b,h}
22242224
// V6_vshuff{b,h}
22252225

2226-
// V6_vshufoe{b,h} those are quivalent to vshuffvdd(..,{1,2})
2226+
// V6_vshufoe{b,h} those are equivalent to vshuffvdd(..,{1,2})
22272227
// V6_vshuffvdd (V6_vshuff)
22282228
// V6_dealvdd (V6_vdeal)
22292229

llvm/lib/Target/Hexagon/HexagonISelLowering.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -814,7 +814,7 @@ SDValue HexagonTargetLowering::LowerFormalArguments(
814814
// stack where the return value will be stored. For Hexagon, the location on
815815
// caller's stack is passed only when the struct size is smaller than (and
816816
// equal to) 8 bytes. If not, no address will be passed into callee and
817-
// callee return the result direclty through R0/R1.
817+
// callee return the result directly through R0/R1.
818818
auto NextSingleReg = [] (const TargetRegisterClass &RC, unsigned Reg) {
819819
switch (RC.getID()) {
820820
case Hexagon::IntRegsRegClassID:
@@ -979,7 +979,7 @@ HexagonTargetLowering::LowerVASTART(SDValue Op, SelectionDAG &DAG) const {
979979
// If first Vararg register is odd, add 4 bytes to start of
980980
// saved register area to point to the first register location.
981981
// This is because the saved register area has to be 8 byte aligned.
982-
// Incase of an odd start register, there will be 4 bytes of padding in
982+
// In case of an odd start register, there will be 4 bytes of padding in
983983
// the beginning of saved register area. If all registers area used up,
984984
// the following condition will handle it correctly.
985985
SDValue SavedRegAreaStartFrameIndex =
@@ -1321,7 +1321,7 @@ HexagonTargetLowering::GetDynamicTLSAddr(SelectionDAG &DAG, SDValue Chain,
13211321
}
13221322

13231323
//
1324-
// Lower using the intial executable model for TLS addresses
1324+
// Lower using the initial executable model for TLS addresses
13251325
//
13261326
SDValue
13271327
HexagonTargetLowering::LowerToTLSInitialExecModel(GlobalAddressSDNode *GA,
@@ -3320,7 +3320,7 @@ HexagonTargetLowering::LowerEH_RETURN(SDValue Op, SelectionDAG &DAG) const {
33203320
Chain = DAG.getStore(Chain, dl, Handler, StoreAddr, MachinePointerInfo());
33213321
Chain = DAG.getCopyToReg(Chain, dl, OffsetReg, Offset);
33223322

3323-
// Not needed we already use it as explict input to EH_RETURN.
3323+
// Not needed we already use it as explicit input to EH_RETURN.
33243324
// MF.getRegInfo().addLiveOut(OffsetReg);
33253325

33263326
return DAG.getNode(HexagonISD::EH_RETURN, dl, MVT::Other, Chain);

llvm/lib/Target/Hexagon/HexagonISelLoweringHVX.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2400,7 +2400,7 @@ HexagonTargetLowering::VectorPair
24002400
HexagonTargetLowering::emitHvxAddWithOverflow(SDValue A, SDValue B,
24012401
const SDLoc &dl, bool Signed, SelectionDAG &DAG) const {
24022402
// Compute A+B, return {A+B, O}, where O = vector predicate indicating
2403-
// whether an overflow has occured.
2403+
// whether an overflow has occurred.
24042404
MVT ResTy = ty(A);
24052405
assert(ResTy == ty(B));
24062406
MVT PredTy = MVT::getVectorVT(MVT::i1, ResTy.getVectorNumElements());
@@ -2911,7 +2911,7 @@ HexagonTargetLowering::CreateTLWrapper(SDValue Op, SelectionDAG &DAG) const {
29112911
#ifndef NDEBUG
29122912
Op.dump(&DAG);
29132913
#endif
2914-
llvm_unreachable("Unepected operator");
2914+
llvm_unreachable("Unexpected operator");
29152915
}
29162916

29172917
const SDLoc &dl(Op);

0 commit comments

Comments
 (0)