---
title: PGO反馈优化
description: "本工具依赖的profile data由反馈优化PGO生成。使用该工具前，建议先熟悉编译器PGO技术的使用方法。"
url: https://www.hikunpeng.com/document/detail/zh/kunpengdevps/compilation/ug-bisheng/kunpengbisheng_30_0035.html
sourcePath: /source/zh/kunpengdevps/compilation/ug-bisheng/kunpengbisheng_30_0035.html
indexId: 266103e951f28cd82a6c4f7d44c803a0a9ba4ae90b7a4c03d8b9aeb42965310e74
---
# PGO反馈优化

本工具依赖的profile data由反馈优化PGO生成。使用该工具前，建议先熟悉编译器PGO技术的使用方法。

常用的PGO方式包括：基于IR插桩的PGO和基于AST插桩的PGO，由于基于IR插桩的PGO缺少必要的源码信息，本工具依赖的profile data来自基于AST插桩方式的PGO。

基于AST插桩方式的PGO使用方法如下：

生成profile：-fprofile-instr-gen=/path/to/***.profrow

使用profile：-fprofile-instr-use=/path/to/***.profdata
