[llvm-dev] SROA for global arrays

Alexey Lapshin via llvm-dev llvm-dev at lists.llvm.org
Thu Mar 25 10:58:34 PDT 2021


Hi Sushant,

llvm already has an implementation for some simple cases of SROA for 
globals.
Check SRAGlobal() from /lib/Transforms/IPO/GlobalOpt.cpp.

Thank you, Alexey.


On 25.03.2021 09:01, sushant gokhale via llvm-dev wrote:
> hi,
>
> My requirement is if I have an global array, then can I break it into 
> individual elements similar to what SROA does ? I know that allocation 
> for globals is different from those of locals but still asking.
>
> Regards
> Sushant
>
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20210325/2cb90aec/attachment.html>


More information about the llvm-dev mailing list