[llvm] dc4a729 - [TableGen] Remove unneeded flush and add missing newline

Fangrui Song via llvm-commits llvm-commits at lists.llvm.org
Sun Nov 13 00:48:56 PST 2022


Author: Fangrui Song
Date: 2022-11-13T00:48:47-08:00
New Revision: dc4a7293a8e760fdec4b134839b2e9cc57119a2f

URL: https://github.com/llvm/llvm-project/commit/dc4a7293a8e760fdec4b134839b2e9cc57119a2f
DIFF: https://github.com/llvm/llvm-project/commit/dc4a7293a8e760fdec4b134839b2e9cc57119a2f.diff

LOG: [TableGen] Remove unneeded flush and add missing newline

Added: 
    

Modified: 
    llvm/utils/TableGen/DecoderEmitter.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/utils/TableGen/DecoderEmitter.cpp b/llvm/utils/TableGen/DecoderEmitter.cpp
index f46cb4c77f6dd..fe53350be5c28 100644
--- a/llvm/utils/TableGen/DecoderEmitter.cpp
+++ b/llvm/utils/TableGen/DecoderEmitter.cpp
@@ -2528,7 +2528,7 @@ static void emitDecodeInstruction(formatted_raw_ostream &OS,
 // DecodeStatus'.)
 static void emitCheck(formatted_raw_ostream &OS) {
   OS << "static bool Check(DecodeStatus &Out, DecodeStatus In) {\n"
-     << "  Out = static_cast<DecodeStatus>(Out & In);"
+     << "  Out = static_cast<DecodeStatus>(Out & In);\n"
      << "  return Out != MCDisassembler::Fail;\n"
      << "}\n\n";
 }
@@ -2685,7 +2685,6 @@ void DecoderEmitter::run(raw_ostream &o) {
 
     // Print the table to the output stream.
     emitTable(OS, TableInfo.Table, 0, FC.getBitWidth(), Opc.first.first);
-    OS.flush();
   }
 
   // For variable instruction, we emit a instruction length table


        


More information about the llvm-commits mailing list