@@ -29,6 +29,10 @@ struct CallSiteInfo {
2929 uint32_t EntryDiscriminator{0 }; // / multiple entry discriminator
3030 uint64_t Count{0 };
3131 uint64_t Mispreds{0 };
32+ // Pseudo probe information, optional
33+ uint32_t Probe{0 };
34+ bool Indirect = false ;
35+ uint32_t InlineTreeNode{0 };
3236
3337 bool operator ==(const CallSiteInfo &Other) const {
3438 return Offset == Other.Offset && DestId == Other.DestId &&
@@ -63,6 +67,9 @@ template <> struct MappingTraits<bolt::CallSiteInfo> {
6367 YamlIO.mapOptional (" disc" , CSI.EntryDiscriminator , (uint32_t )0 );
6468 YamlIO.mapRequired (" cnt" , CSI.Count );
6569 YamlIO.mapOptional (" mis" , CSI.Mispreds , (uint64_t )0 );
70+ YamlIO.mapOptional (" pp" , CSI.Probe , 0 );
71+ YamlIO.mapOptional (" ppn" , CSI.InlineTreeNode , 0 );
72+ YamlIO.mapOptional (" ind" , CSI.Indirect , false );
6673 }
6774
6875 static const bool flow = true ;
@@ -95,29 +102,20 @@ template <> struct MappingTraits<bolt::SuccessorInfo> {
95102
96103namespace bolt {
97104struct PseudoProbeInfo {
98- uint32_t InlineTreeIndex = 0 ;
99- uint64_t BlockMask = 0 ; // bitset with probe indices from 1 to 64
100- std::vector<uint64_t > BlockProbes; // block probes with indices above 64
101- std::vector<uint64_t > CallProbes;
102- std::vector<uint64_t > IndCallProbes;
105+ std::vector<uint64_t > BlockProbes;
103106 std::vector<uint32_t > InlineTreeNodes;
104107
105108 bool operator ==(const PseudoProbeInfo &Other) const {
106- return InlineTreeIndex == Other.InlineTreeIndex &&
107- BlockProbes == Other.BlockProbes && CallProbes == Other.CallProbes &&
108- IndCallProbes == Other.IndCallProbes ;
109+ return InlineTreeNodes == Other.InlineTreeNodes &&
110+ BlockProbes == Other.BlockProbes ;
109111 }
110112};
111113} // end namespace bolt
112114
113115template <> struct MappingTraits <bolt::PseudoProbeInfo> {
114116 static void mapping (IO &YamlIO, bolt::PseudoProbeInfo &PI) {
115- YamlIO.mapOptional (" blx" , PI.BlockMask , 0 );
116- YamlIO.mapOptional (" blk" , PI.BlockProbes , std::vector<uint64_t >());
117- YamlIO.mapOptional (" call" , PI.CallProbes , std::vector<uint64_t >());
118- YamlIO.mapOptional (" icall" , PI.IndCallProbes , std::vector<uint64_t >());
119- YamlIO.mapOptional (" id" , PI.InlineTreeIndex , 0 );
120- YamlIO.mapOptional (" ids" , PI.InlineTreeNodes , std::vector<uint32_t >());
117+ YamlIO.mapOptional (" blk" , PI.BlockProbes , std::vector<uint64_t >(1 , 1 ));
118+ YamlIO.mapOptional (" ids" , PI.InlineTreeNodes , std::vector<uint32_t >(1 , 0 ));
121119 }
122120
123121 static const bool flow = true ;
0 commit comments