Skip to content

Commit

Permalink
llvm-16-compile-fix google#168
Browse files Browse the repository at this point in the history
  • Loading branch information
20083017 committed May 21, 2023
1 parent 7d9722d commit 6dc5403
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
7 changes: 3 additions & 4 deletions llvm_propeller_profile_writer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ void DumpCfgs(
} // namespace

namespace devtools_crosstool_autofdo {

using ::devtools_crosstool_autofdo::PropellerOptions;
using ::llvm::StringRef;

Expand Down Expand Up @@ -252,7 +251,7 @@ bool PropellerProfWriter::Write(
total_clusters += func_cluster_info.clusters.size();

// Allocate the symbol order vector
std::vector<std::pair<llvm::SmallVector<StringRef, 3>,
std::vector<std::pair<::llvm::SmallVector<StringRef, 3>,
std::optional<unsigned>>>symbol_order(total_clusters);
// Allocate the cold symbol order vector equally sized as
// all_functions_cluster_info, as there is (at most) one cold cluster per
Expand All @@ -272,7 +271,7 @@ bool PropellerProfWriter::Write(
func_layout_info.optimized_score.inter_out_score;

// Print all alias names of the function, separated by '/'.
out_stream << "!" << llvm::join(func_layout_info.cfg->names(), "/") << "\n";
out_stream << "!" << ::llvm::join(func_layout_info.cfg->names(), "/") << "\n";

if (options_.verbose_cluster_output()) {
// Print the layout score for intra-function and inter-function edges
Expand All @@ -295,7 +294,7 @@ bool PropellerProfWriter::Write(
// the function name is sufficient for section ordering. Otherwise,
// the cluster number is required.
symbol_order[cluster.layout_index] =
std::pair<llvm::SmallVector<StringRef, 3>, std::optional<unsigned>>(
std::pair<::llvm::SmallVector<StringRef, 3>, std::optional<unsigned>>(
func_layout_info.cfg->names_, cluster.bb_indexes.front() == 0
? std::optional<unsigned>()
: cluster_id);
Expand Down
2 changes: 1 addition & 1 deletion llvm_propeller_whole_program_info.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class PropellerWholeProgramInfo : public AbstractPropellerWholeProgramInfo {
bool binary_is_pie() const { return binary_perf_info_.binary_info.is_pie; }

// Getters.
const string binary_build_id() const {
const std::string binary_build_id() const {
return binary_perf_info_.binary_info.build_id;
}

Expand Down

0 comments on commit 6dc5403

Please sign in to comment.