I encountered a weird result while inspecting assembly for my piece of code compiled with opt-level=s
:
It looks as if dead code elimination was not applied here for some reason. The assembly generated for to_u32s
(the only public function in the crate) does not call any other code snippets presented in the generated assembly. Is it expected? I know that unused functions may be eliminated later by linker, but it still looks weird.