banach-space / llvm-tutor

A collection of out-of-tree LLVM passes for teaching and learning
MIT License
2.95k stars 393 forks source link

Add extension points for TargetPassConfig::addMachinePasses #79

Open ssarfaty opened 1 year ago

ssarfaty commented 1 year ago

in LLVM 16 the Add extension points for MachinePass should be availible, i couldn't find a way to write a plugin in LLVM that can change the function prologue and epilogue that the MachinePass creates..

do you have such example ?

banach-space commented 1 year ago

Hello 👋🏻 !

do you have such example ?

I do not. Would you like to contribute one? :)

-Andrzej

ssarfaty commented 1 year ago

thats the problem with LLVM .. the new pass manager should have support also like GCC RTL pass the ASM changes but not many example exist ... for GCC there are some that change the Canary implementation: https://github.com/enferex/sataniccanary/blob/master/sataniccanary.c

i'm looking for such example in LLVM ...