1/6

A generic function is not one function. The compiler monomorphizes it: for every concrete type it is called with, it stamps out a separate specialised copy.

fn emit<T: Debug>(label: &str, value: T) { ... }

emit("count", 42u32);        // emits emit::<u32>
emit("name", "rpc");         // emits emit::<&str>
emit("flags", vec![true]);   // emits emit::<Vec<bool>>

Three call sites, three real functions in the binary. Each one knows its concrete type, so every method call inside is a direct call — no indirection, fully inlinable.