================
@@ -3430,13 +3430,25 @@ void FunctionStackPoisoner::processStaticAllocas() {
   SmallVector<ASanStackVariableDescription, 16> SVD;
   SVD.reserve(AllocaVec.size());
   for (AllocaInst *AI : AllocaVec) {
-    ASanStackVariableDescription D = {AI->getName().data(),
-                                      ASan.getAllocaSizeInBytes(*AI),
-                                      0,
-                                      AI->getAlign().value(),
-                                      AI,
-                                      0,
-                                      0};
+    StringRef Name = AI->getName();
+    if (AI->hasMetadata(LLVMContext::MD_annotation)) {
+      MDTuple *Annotation = (MDTuple 
*)AI->getMetadata(LLVMContext::MD_annotation);
----------------
vitalybuka wrote:

it would be nice to have it into some utility function
getAllocaOriginalName(AI) or something.



https://github.com/llvm/llvm-project/pull/119387
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to