Merge pull request #513 from practicalswift/fix-typos-17

Fix typos (17 of 30)
This commit is contained in:
Dmitri Gribenko
2015-12-14 01:11:28 -08:00
10 changed files with 13 additions and 13 deletions

View File

@@ -205,7 +205,7 @@ using LSValueIndexMap = llvm::DenseMap<LSValue, unsigned>;
using ValueTableMap = llvm::SmallMapVector<unsigned, unsigned, 8>; using ValueTableMap = llvm::SmallMapVector<unsigned, unsigned, 8>;
/// This class represents either a single SILValue or a covering of values that /// This class represents either a single SILValue or a covering of values that
/// we can forward from via the introdution of a SILArgument. This enables us /// we can forward from via the introduction of a SILArgument. This enables us
/// to treat the case of having one value or multiple values and load and store /// to treat the case of having one value or multiple values and load and store
/// cases all at once abstractly and cleanly. /// cases all at once abstractly and cleanly.
/// ///

View File

@@ -12,7 +12,7 @@
// //
// This is an analysis that determines the ref count identity (i.e. gc root) of // This is an analysis that determines the ref count identity (i.e. gc root) of
// a pointer. Any values with the same ref count identity are able to be // a pointer. Any values with the same ref count identity are able to be
// retained and released interchangably. // retained and released interchangeably.
// //
//===----------------------------------------------------------------------===// //===----------------------------------------------------------------------===//

View File

@@ -304,7 +304,7 @@ void SILGlobalOpt::collectOnceCall(BuiltinInst *BI) {
if (!Callee->getName().startswith("globalinit_")) if (!Callee->getName().startswith("globalinit_"))
return; return;
// We currently disable optimizing the intializer if a globalinit_func // We currently disable optimizing the initializer if a globalinit_func
// is called by "once" from multiple locations. // is called by "once" from multiple locations.
if (!BI->getFunction()->isGlobalInit()) if (!BI->getFunction()->isGlobalInit())
// If a globalinit_func is called by "once" from a function that is not // If a globalinit_func is called by "once" from a function that is not
@@ -454,7 +454,7 @@ void SILGlobalOpt::placeInitializers(SILFunction *InitF,
} }
} }
/// Create a getter function from the intializer function. /// Create a getter function from the initializer function.
static SILFunction *genGetterFromInit(SILFunction *InitF, VarDecl *varDecl) { static SILFunction *genGetterFromInit(SILFunction *InitF, VarDecl *varDecl) {
// Generate a getter from the global init function without side-effects. // Generate a getter from the global init function without side-effects.
llvm::SmallString<20> getterBuffer; llvm::SmallString<20> getterBuffer;

View File

@@ -1806,7 +1806,7 @@ private:
// We have a safe container if the array container is passed as a function // We have a safe container if the array container is passed as a function
// argument by-value or by inout reference. In either case there can't be an // argument by-value or by inout reference. In either case there can't be an
// alias of the container. Alternatively, we can have a local variable. We // alias of the container. Alternatively, we can have a local variable. We
// will check in checkSafeArrayAddressUses that all intialization stores to // will check in checkSafeArrayAddressUses that all initialization stores to
// this variable are safe (i.e the store dominates the loop etc). // this variable are safe (i.e the store dominates the loop etc).
bool isSafeArrayContainer(SILValue V) { bool isSafeArrayContainer(SILValue V) {
if (auto *Arg = dyn_cast<SILArgument>(V.getDef())) { if (auto *Arg = dyn_cast<SILArgument>(V.getDef())) {

View File

@@ -520,7 +520,7 @@ void DSEContext::invalidateLSLocationBase(SILInstruction *I,
void DSEContext::updateWriteSetForRead(BlockState *S, unsigned bit) { void DSEContext::updateWriteSetForRead(BlockState *S, unsigned bit) {
// Remove any may/must-aliasing stores to the LSLocation, as they cant be // Remove any may/must-aliasing stores to the LSLocation, as they cant be
// used to kill any upward visible stores due to the intefering load. // used to kill any upward visible stores due to the interfering load.
LSLocation &R = LSLocationVault[bit]; LSLocation &R = LSLocationVault[bit];
for (unsigned i = 0; i < S->LSLocationNum; ++i) { for (unsigned i = 0; i < S->LSLocationNum; ++i) {
if (!S->isTrackingLSLocation(i)) if (!S->isTrackingLSLocation(i))

View File

@@ -505,7 +505,7 @@ void BlockState::updateForwardSetForWrite(RLEContext &Ctx, unsigned LBit,
LSLocation &L = Ctx.getLSLocation(i); LSLocation &L = Ctx.getLSLocation(i);
if (!L.isMayAliasLSLocation(R, Ctx.getAA())) if (!L.isMayAliasLSLocation(R, Ctx.getAA()))
continue; continue;
// MayAlias, invaliate the LSLocation. // MayAlias, invalidate the LSLocation.
stopTrackingLSLocation(i); stopTrackingLSLocation(i);
} }

View File

@@ -1175,7 +1175,7 @@ static SILValue skipInvert(SILValue Cond, bool &Inverted,
OperandValueArrayRef Args = BI->getArguments(); OperandValueArrayRef Args = BI->getArguments();
if (BI->getBuiltinInfo().ID == BuiltinValueKind::Xor) { if (BI->getBuiltinInfo().ID == BuiltinValueKind::Xor) {
// Check if it's a boolean invertion of the condition. // Check if it's a boolean inversion of the condition.
if (auto *IL = dyn_cast<IntegerLiteralInst>(Args[1])) { if (auto *IL = dyn_cast<IntegerLiteralInst>(Args[1])) {
if (IL->getValue().isAllOnesValue()) { if (IL->getValue().isAllOnesValue()) {
Cond = Args[0]; Cond = Args[0];
@@ -1302,7 +1302,7 @@ bool SimplifyCFG::simplifyCondBrBlock(CondBranchInst *BI) {
if (auto *Xor = if (auto *Xor =
dyn_cast<BuiltinInst>(BI->getCondition().stripExpectIntrinsic())) { dyn_cast<BuiltinInst>(BI->getCondition().stripExpectIntrinsic())) {
if (Xor->getBuiltinInfo().ID == BuiltinValueKind::Xor) { if (Xor->getBuiltinInfo().ID == BuiltinValueKind::Xor) {
// Check if it's a boolean invertion of the condition. // Check if it's a boolean inversion of the condition.
OperandValueArrayRef Args = Xor->getArguments(); OperandValueArrayRef Args = Xor->getArguments();
if (auto *IL = dyn_cast<IntegerLiteralInst>(Args[1])) { if (auto *IL = dyn_cast<IntegerLiteralInst>(Args[1])) {
if (IL->getValue().isAllOnesValue()) { if (IL->getValue().isAllOnesValue()) {

View File

@@ -1147,7 +1147,7 @@ public:
/// of printing diagnostics. /// of printing diagnostics.
/// ///
/// \returns a CheckedCastKind indicating the semantics of the cast. If the /// \returns a CheckedCastKind indicating the semantics of the cast. If the
/// cast is invald, Unresolved is returned. If the cast represents an implicit /// cast is invalid, Unresolved is returned. If the cast represents an implicit
/// conversion, Coercion is returned. /// conversion, Coercion is returned.
CheckedCastKind typeCheckCheckedCast(Type fromType, CheckedCastKind typeCheckCheckedCast(Type fromType,
Type toType, Type toType,

View File

@@ -246,7 +246,7 @@ simdTestSuite.test("matrix init") {
% mat = 'm_' + mattype % mat = 'm_' + mattype
% diagsize = rows if rows < cols else cols % diagsize = rows if rows < cols else cols
// Check empty intializer. // Check empty initializer.
var ${mat} = ${mattype}() var ${mat} = ${mattype}()
expectEqual(${mat}, ${mattype}(${[[0]*rows]*cols}), sameValue: same) expectEqual(${mat}, ${mattype}(${[[0]*rows]*cols}), sameValue: same)

View File

@@ -10,7 +10,7 @@
// FIXME: This test is written in Swift instead of SIL, because there are some problems // FIXME: This test is written in Swift instead of SIL, because there are some problems
// with SIL deserialization (rdar://22636911) // with SIL deserialization (rdar://22636911)
// Check that intializers do not contain a code to intialize private or // Check that initializers do not contain a code to initialize private or
// internal (if used with WMO) properties, because their values are propagated into // internal (if used with WMO) properties, because their values are propagated into
// their uses and they cannot be accessed from other modules. Therefore the // their uses and they cannot be accessed from other modules. Therefore the
// initialization code could be removed. // initialization code could be removed.
@@ -36,7 +36,7 @@
// CHECK-WMO: ref_element_addr %{{[0-9]+}} : $Foo, #Foo.Prop3 // CHECK-WMO: ref_element_addr %{{[0-9]+}} : $Foo, #Foo.Prop3
// CHECK-WMO: return // CHECK-WMO: return
// Check that intializers do not contain a code to intialize private properties, // Check that initializers do not contain a code to initialize private properties,
// because their values are propagated into their uses and they cannot be accessed // because their values are propagated into their uses and they cannot be accessed
// from other modules. Therefore the initialization code could be removed. // from other modules. Therefore the initialization code could be removed.
// Specifically, the initialization code for Prop2 can be removed. // Specifically, the initialization code for Prop2 can be removed.