Skip to content

Commit

Permalink
[XLA:GPU][IndexAnalysis] Use the correct type for Range, RT and Dim v…
Browse files Browse the repository at this point in the history
…ars.

PiperOrigin-RevId: 692226529
  • Loading branch information
pifon2a authored and tensorflower-gardener committed Nov 1, 2024
1 parent 718d56c commit b6e6753
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -906,7 +906,7 @@ SmallVector<std::string> GetRangeVarNames(const IndexingMap& map) {
}

SmallVector<std::string> GetRTVarNames(const IndexingMap& map) {
SmallVector<std::string, 3> rt_names;
SmallVector<std::string> rt_names;
rt_names.reserve(map.GetRTVarsCount());
for (const auto& [index, rt_var] : llvm::enumerate(map.GetRTVars())) {
rt_names.push_back(GetRTVarName(index, rt_var.name));
Expand All @@ -915,7 +915,7 @@ SmallVector<std::string> GetRTVarNames(const IndexingMap& map) {
}

SmallVector<std::string> GetDimVarNames(const IndexingMap& map) {
SmallVector<std::string, 3> dim_names;
SmallVector<std::string> dim_names;
dim_names.reserve(map.GetDimVarsCount());
for (const auto& [index, dim_var] : llvm::enumerate(map.GetDimVars())) {
dim_names.push_back(GetDimVarName(index, dim_var.name));
Expand All @@ -924,7 +924,7 @@ SmallVector<std::string> GetDimVarNames(const IndexingMap& map) {
}

SmallVector<std::string> GetSymbolVarNames(const IndexingMap& map) {
SmallVector<std::string, 3> symbol_names;
SmallVector<std::string> symbol_names;
auto range_names = GetRangeVarNames(map);
auto rt_names = GetRTVarNames(map);
symbol_names.reserve(range_names.size() + rt_names.size());
Expand Down

0 comments on commit b6e6753

Please sign in to comment.