@@ -20,7 +20,7 @@ namespace llvm {
2020namespace mca {
2121
2222void InstructionInfoView::getComment (const MCInst &MCI,
23- std::string &CommentString) const {
23+ std::string &CommentString) const {
2424 StringRef s = MCI.getLoc ().getPointer ();
2525 std::string InstrStr;
2626 size_t pos = 0 , pos_cmt = 0 ;
@@ -143,11 +143,11 @@ void InstructionInfoView::printView(raw_ostream &OS) const {
143143
144144 if (PrintSchedulingInfo) {
145145 if (PrintEncodings)
146- WithColor::warning ()
147- << " No encodings printed when -scheduling-info option enabled.\n " ;
146+ WithColor::warning ()
147+ << " No encodings printed when -scheduling-info option enabled.\n " ;
148148 if (PrintBarriers)
149- WithColor::warning ()
150- << " No barrier printed when -scheduling-info option enabled.\n " ;
149+ WithColor::warning ()
150+ << " No barrier printed when -scheduling-info option enabled.\n " ;
151151
152152 printSchedulingInfoView (OS);
153153 return ;
@@ -269,27 +269,28 @@ void InstructionInfoView::collectData(
269269 if (PrintSchedulingInfo) {
270270 // Get latency with bypass
271271 IIVDEntry.Bypass =
272- IIVDEntry.Latency - MCSchedModel::getBypassDelayCycles (STI, SCDesc);
272+ IIVDEntry.Latency - MCSchedModel::getBypassDelayCycles (STI, SCDesc);
273273 IIVDEntry.OpcodeName = (std::string)MCII.getName (Inst.getOpcode ());
274274 raw_string_ostream TempStream (IIVDEntry.Resources );
275275 const MCWriteProcResEntry *Index = STI.getWriteProcResBegin (&SCDesc);
276276 const MCWriteProcResEntry *Last = STI.getWriteProcResEnd (&SCDesc);
277277 auto sep = " " ;
278278 for (; Index != Last; ++Index) {
279- if (!Index->ReleaseAtCycle )
280- continue ;
281- const MCProcResourceDesc *MCProc =
282- SM.getProcResource (Index->ProcResourceIdx );
283- if (Index->ReleaseAtCycle > 1 ) {
284- // Output ReleaseAtCycle between [] if not 1 (default)
285- // This is to be able to evaluate throughput.
286- // See getReciprocalThroughput in MCSchedule.cpp
287- // TODO: report AcquireAtCycle to check this scheduling info.
288- TempStream << sep << format (" %s[%d]" , MCProc->Name , Index->ReleaseAtCycle );
289- } else {
290- TempStream << sep << format (" %s" , MCProc->Name );
291- }
292- sep = " ," ;
279+ if (!Index->ReleaseAtCycle )
280+ continue ;
281+ const MCProcResourceDesc *MCProc =
282+ SM.getProcResource (Index->ProcResourceIdx );
283+ if (Index->ReleaseAtCycle > 1 ) {
284+ // Output ReleaseAtCycle between [] if not 1 (default)
285+ // This is to be able to evaluate throughput.
286+ // See getReciprocalThroughput in MCSchedule.cpp
287+ // TODO: report AcquireAtCycle to check this scheduling info.
288+ TempStream << sep
289+ << format (" %s[%d]" , MCProc->Name , Index->ReleaseAtCycle );
290+ } else {
291+ TempStream << sep << format (" %s" , MCProc->Name );
292+ }
293+ sep = " ," ;
293294 }
294295 TempStream.flush ();
295296 }
0 commit comments