Does libnvvm expect the user to run LLVM passes first?

Hello!

I am writing a compiler backend for the rust language compiler, and i am getting some subpar output from libnvvm. It appears to include every single function even if its not a public kernel function, which leads to about a 10mb ptx file which is not ideal. Moreover, when comparing gpu and cpu code, libnvvm does not perform much inlining, if any. I was wondering if this is because libnvvm expects you to run the normal llvm passes first, i could not find any documentation on this topic.