[llvm-dev] Adding a custom section to ELF file

Tom Stellard via llvm-dev llvm-dev at lists.llvm.org
Wed Nov 18 06:56:45 PST 2015


On Wed, Nov 18, 2015 at 03:09:44PM +0100, Sky Flyer via llvm-dev wrote:
> Hi all,
> 
> how can I add my own section to the ELF file to write some target-specific
> parameters?
> Is there any sample in the LLVM examples?
> 

AMDGPU backend does this.  grep the code for 'SwitchSection' and take a
look at AMDGPUHSATargetObjectFile.cpp

-Tom

> Cheers,
> ES

> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev



More information about the llvm-dev mailing list