[llvm] [NVPTX] use incomplete aggregate initializers (PR #79062)

Alex MacLean via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 22 17:00:51 PST 2024


================
@@ -1292,10 +1292,20 @@ void NVPTXAsmPrinter::AggBuffer::printSymbol(unsigned nSym, raw_ostream &os) {
 
 void NVPTXAsmPrinter::AggBuffer::printBytes(raw_ostream &os) {
   unsigned int ptrSize = AP.MAI->getCodePointerSize();
-  symbolPosInBuffer.push_back(size);
+  // Last contingous sequnce of 0 bytes are unintialized to get default
+  // initialization in ptxas. This avoids ptxas memory consumption for large
+  // aggregates.
----------------
AlexMaclean wrote:

Rephrased. 

>  Speaking of memory use, do you have any specific data on how much that affects ptxas?

Sorry, I don't have any specific data. 

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


More information about the llvm-commits mailing list