Skip to content

Commit

Permalink
[SYCLomatic][NFC]Corrected spelling mistake in word 'migration' (#2410)
Browse files Browse the repository at this point in the history
  • Loading branch information
TejaX-Alaghari authored Oct 14, 2024
1 parent 8843cc1 commit 9435aac
Show file tree
Hide file tree
Showing 15 changed files with 35 additions and 35 deletions.
2 changes: 1 addition & 1 deletion clang/lib/DPCT/ASTTraversal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2246,7 +2246,7 @@ void TypeInDeclRule::runRule(const MatchFinder::MatchResult &Result) {
TypePtr = ET->getNamedType().getTypePtr();

// The definition of the type is in current files for analysis and
// neither they are typedefed. We donot want to migarte such types.
// neither they are typedefed. We donot want to migrate such types.
if (TypePtr->getTypeClass() != clang::Type::Typedef)
return;

Expand Down
6 changes: 3 additions & 3 deletions clang/lib/DPCT/BLASAPIMigration.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//

#ifndef DPCT_BLAS_API_MIGRAION_H
#define DPCT_BLAS_API_MIGRAION_H
#ifndef DPCT_BLAS_API_MIGRATION_H
#define DPCT_BLAS_API_MIGRATION_H

#include "CallExprRewriter.h"

Expand Down Expand Up @@ -117,4 +117,4 @@ bool checkConstQualifierInDoublePointerType(
} // namespace dpct
} // namespace clang

#endif // !DPCT_BLAS_API_MIGRAION_H
#endif // !DPCT_BLAS_API_MIGRATION_H
6 changes: 3 additions & 3 deletions clang/lib/DPCT/DNNAPIMigration.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
//
//===-----------------------------------------------------------------===//

#ifndef DPCT_DNN_API_MIGRAION_H
#define DPCT_DNN_API_MIGRAION_H
#ifndef DPCT_DNN_API_MIGRATION_H
#define DPCT_DNN_API_MIGRATION_H

#include "ASTTraversal.h"
#include "clang/ASTMatchers/ASTMatchFinder.h"
Expand All @@ -34,4 +34,4 @@ class CuDNNAPIRule : public NamedMigrationRule<CuDNNAPIRule> {
} // namespace dpct
} // namespace clang

#endif // !DPCT_DNN_API_MIGRAION_H
#endif // !DPCT_DNN_API_MIGRATION_H
8 changes: 4 additions & 4 deletions clang/lib/DPCT/DPCT.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -752,12 +752,12 @@ int runDPCT(int argc, const char **argv) {

if (BuildScript == BuildScriptKind::BS_Cmake &&
!OptParser->getSourcePathList().empty()) {
ShowStatus(MigarteBuildScriptIncorrectUse);
dpctExit(MigarteBuildScriptIncorrectUse);
ShowStatus(MigrateBuildScriptIncorrectUse);
dpctExit(MigrateBuildScriptIncorrectUse);
}
if (BuildScript == BuildScriptKind::BS_Cmake && MigrateBuildScriptOnly) {
ShowStatus(MigarteBuildScriptAndMigarteBuildScriptOnlyBothUse);
dpctExit(MigarteBuildScriptAndMigarteBuildScriptOnlyBothUse);
ShowStatus(MigrateBuildScriptAndMigrateBuildScriptOnlyBothUse);
dpctExit(MigrateBuildScriptAndMigrateBuildScriptOnlyBothUse);
}

int SDKIncPathRes = checkSDKPathOrIncludePath(CudaIncludePath);
Expand Down
6 changes: 3 additions & 3 deletions clang/lib/DPCT/Error.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -197,13 +197,13 @@ void ShowStatus(int Status, std::string Message) {
case MigrateCmakeScriptOnlyNotSpecifed:
StatusString =
"Error: option '-migrate-build-script-only' is not specified "
"for CMake script migartion.";
"for CMake script migration.";
break;
case MigarteBuildScriptIncorrectUse:
case MigrateBuildScriptIncorrectUse:
StatusString = "Error: option '-migrate-build-script' is only used for "
"whole project code migration.";
break;
case MigarteBuildScriptAndMigarteBuildScriptOnlyBothUse:
case MigrateBuildScriptAndMigrateBuildScriptOnlyBothUse:
StatusString = "Error: option '-migrate-build-script' and "
"'-migrate-build-script-only' cannot be used together.";
break;
Expand Down
4 changes: 2 additions & 2 deletions clang/lib/DPCT/Error.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ enum ProcessStatus {
CallIndependentToolError = -47,
MigrationErrorCMakeScriptPathInvalid = -48,
MigrateCmakeScriptOnlyNotSpecifed = -49,
MigarteBuildScriptIncorrectUse = -50,
MigarteBuildScriptAndMigarteBuildScriptOnlyBothUse = -51,
MigrateBuildScriptIncorrectUse = -50,
MigrateBuildScriptAndMigrateBuildScriptOnlyBothUse = -51,
MigrationErrorNoExplicitInRootAndCMakeScript = -52,
MigrationErrorCannotWrite = -53,
};
Expand Down
6 changes: 3 additions & 3 deletions clang/lib/DPCT/FFTAPIMigration.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//

#ifndef DPCT_FFT_API_MIGRAION_H
#define DPCT_FFT_API_MIGRAION_H
#ifndef DPCT_FFT_API_MIGRATION_H
#define DPCT_FFT_API_MIGRATION_H

#include "MapNames.h"
#include "TextModification.h"
Expand All @@ -20,4 +20,4 @@ TextModification *processFunctionPointer(const UnaryOperator *UO);
} // namespace dpct
} // namespace clang

#endif // !DPCT_FFT_API_MIGRAION_H
#endif // !DPCT_FFT_API_MIGRATION_H
6 changes: 3 additions & 3 deletions clang/lib/DPCT/LibraryAPIMigration.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//

#ifndef DPCT_LIBRARY_API_MIGRAION_H
#define DPCT_LIBRARY_API_MIGRAION_H
#ifndef DPCT_LIBRARY_API_MIGRATION_H
#define DPCT_LIBRARY_API_MIGRATION_H

#include "ExprAnalysis.h"
#include "MapNames.h"
Expand Down Expand Up @@ -98,4 +98,4 @@ void initVars(const CallExpr *CE, const VarDecl *VD, const BinaryOperator *BO,
} // namespace dpct
} // namespace clang

#endif // !DPCT_LIBRARY_API_MIGRAION_H
#endif // !DPCT_LIBRARY_API_MIGRATION_H
4 changes: 2 additions & 2 deletions clang/lib/DPCT/MigrateCmakeScript.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ static std::map<std::string /*variable name*/, std::string /*value*/>
CmakeVarMap;

static std::map<std::string /*cmake syntax*/,
MetaRuleObject::PatternRewriter /*cmake migraiton rule*/>
MetaRuleObject::PatternRewriter /*cmake migration rule*/>
CmakeBuildInRules;

static std::map<std::string /*file path*/,
Expand Down Expand Up @@ -764,7 +764,7 @@ void registerCmakeMigrationRule(MetaRuleObject &R) {
} else {
llvm::outs() << "[Warnning]: Two migration rules (Rule:" << R.RuleId
<< ", Rule:" << Iter->second.RuleId
<< ") are duplicated, the migrtion rule (Rule:" << R.RuleId
<< ") are duplicated, the migration rule (Rule:" << R.RuleId
<< ") is ignored.\n";
}
} else {
Expand Down
6 changes: 3 additions & 3 deletions clang/lib/DPCT/OptimizeMigration.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
//
//===-----------------------------------------------------------------===//

#ifndef DPCT_OPTIMIZE_MIGRAION_H
#define DPCT_OPTIMIZE_MIGRAION_H
#ifndef DPCT_OPTIMIZE_MIGRATION_H
#define DPCT_OPTIMIZE_MIGRATION_H

#include "ASTTraversal.h"
#include "clang/ASTMatchers/ASTMatchFinder.h"
Expand All @@ -31,4 +31,4 @@ class DeviceConstantVarOptimizeAnalysisRule
} // namespace dpct
} // namespace clang

#endif // !DPCT_OPTIMIZE_MIGRAION_H
#endif // !DPCT_OPTIMIZE_MIGRATION_H
4 changes: 2 additions & 2 deletions clang/test/dpct/cmake_migration/case_011/expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ target_compile_features(culib
PUBLIC
cxx_std_17)

#Currently the Yaml based migartion rule migartes CXX and CUDA std_20 down to std_17.
#Currently the Yaml based migration rule migrates CXX and CUDA std_20 down to std_17.
#An implicit migration rule will be implemented to fix this issue in future.
#TARGET_COMPILE_FEATURES(cuexe PUBLIC c_std_20)
#target_compile_features(cuexe PRIVATE cxx_std_20)
#target_compile_features(cuexe
# PUBLIC
# cuda_std_20)

#Currently the Yaml based migartion rule migartes CXX and CUDA std_23 down to std_17.
#Currently the Yaml based migration rule migrates CXX and CUDA std_23 down to std_17.
#An implicit migration rule will be implemented to fix this issue in future.
#TARGET_COMPILE_FEATURES(cuexe PUBLIC c_std_23)
#target_compile_features(cuexe PRIVATE cxx_std_23)
Expand Down
4 changes: 2 additions & 2 deletions clang/test/dpct/cmake_migration/case_011/input.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ target_compile_features(culib
PUBLIC
cuda_std_17)

#Currently the Yaml based migartion rule migartes CXX and CUDA std_20 down to std_17.
#Currently the Yaml based migration rule migrates CXX and CUDA std_20 down to std_17.
#An implicit migration rule will be implemented to fix this issue in future.
#TARGET_COMPILE_FEATURES(cuexe PUBLIC c_std_20)
#target_compile_features(cuexe PRIVATE cxx_std_20)
#target_compile_features(cuexe
# PUBLIC
# cuda_std_20)

#Currently the Yaml based migartion rule migartes CXX and CUDA std_23 down to std_17.
#Currently the Yaml based migration rule migrates CXX and CUDA std_23 down to std_17.
#An implicit migration rule will be implemented to fix this issue in future.
#TARGET_COMPILE_FEATURES(cuexe PUBLIC c_std_23)
#target_compile_features(cuexe PRIVATE cxx_std_23)
Expand Down
2 changes: 1 addition & 1 deletion clang/test/dpct/cmake_migration/case_021/expected.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ add_compile_options(-std=c++17)
add_compile_options(-std=c++17)
add_compile_options(-std=c++17)

#Currently we use Yaml based migartion rule to migarte -std=c++22 down to -std=c++17.
#Currently we use Yaml based migration rule to migrate -std=c++22 down to -std=c++17.
#We will implement an implicit migration rule to fix this issue in future.
#add_compile_options(-std=c++22)
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++22")
Expand Down
2 changes: 1 addition & 1 deletion clang/test/dpct/cmake_migration/case_021/input.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ add_compile_options(-std=c++11)
add_compile_options(-std=c++14)
add_compile_options(-std=c++17)

#Currently we use Yaml based migartion rule to migarte -std=c++22 down to -std=c++17.
#Currently we use Yaml based migration rule to migrate -std=c++22 down to -std=c++17.
#We will implement an implicit migration rule to fix this issue in future.
#add_compile_options(-std=c++22)
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++22")
Expand Down
4 changes: 2 additions & 2 deletions clang/test/dpct/cmake_migration/case_044/ref.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
// CHECK: [Warnning]: Two migration rules (Rule:rule_gen_codes_add_link_options_test_dup, Rule:rule_gen_codes_add_link_options) are duplicated, the migrtion rule (Rule:rule_gen_codes_add_link_options_test_dup) is ignored.
// CHECK: [Warnning]: Two migration rules (Rule:rule_a_new, Rule:rule_a_old) are duplicated, the migrtion rule (Rule:rule_a_new) is ignored.
// CHECK: [Warnning]: Two migration rules (Rule:rule_gen_codes_add_link_options_test_dup, Rule:rule_gen_codes_add_link_options) are duplicated, the migration rule (Rule:rule_gen_codes_add_link_options_test_dup) is ignored.
// CHECK: [Warnning]: Two migration rules (Rule:rule_a_new, Rule:rule_a_old) are duplicated, the migration rule (Rule:rule_a_new) is ignored.

0 comments on commit 9435aac

Please sign in to comment.