> Does gcc use LLVM anywhere under the hood or it has its own code generation and optimization pipeline?
No it doesn't use LLVM
> How does it stack in comparison to LLVM?
Well it support more targets then LLVM and in most cases it generates similar if not better executable.