[clang] [AST][RISCV] Preserve RISC-V intrinsic pragma in AST (PR #171981)

Craig Topper via cfe-commits cfe-commits at lists.llvm.org
Fri Dec 12 09:07:42 PST 2025


================
@@ -5232,6 +5233,15 @@ void ASTWriter::WriteModuleFileExtension(Sema &SemaRef,
   Stream.ExitBlock();
 }
 
+void ASTWriter::WriteRISCVIntrinsicPragmas(Sema &SemaRef) {
+  RecordData Record;
+  Record.push_back(SemaRef.RISCV().DeclareRVVBuiltins);
+  Record.push_back(SemaRef.RISCV().DeclareSiFiveVectorBuiltins);
+  Record.push_back(SemaRef.RISCV().DeclareAndesVectorBuiltins);
+  Record.push_back(Record.size());
----------------
topperc wrote:

Why is the size pushed last? Why not first?

https://github.com/llvm/llvm-project/pull/171981


More information about the cfe-commits mailing list