https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99789
--- Comment #9 from cqwrteur <unlvsur at live dot com> --- (In reply to Jakub Jelinek from comment #8) > Bugzilla is for reporting bugs, not for general programming advices. > > There is no bug here, the C++ standard for 64-bit architectures with its > requirements on std::string_view etc. effectively mandates that the class > stores a pointer and size which better should be also size_t and not > something narrower. > And you or your users made a choice of some ABI where passing this by value > means it is not passed in registers. but how rust works with that? Rust did pass them by registers even on msvc abi which makes me curious. I think I can send you the assembly file.