News for hackers. Stuff that matters.
Re:Learning to Read X86 Assembly Language by makmanalp on Sunday November 27, 2016 @07:56PM (#13052683)
> If you're compiling Rust code that calls into a C library, how does it know what registers to use?

Ah, interesting, I figured that the generated object files would just store some metadata on that basically.

Re:Learning to Read X86 Assembly Language by MichaelBurge on Sunday November 27, 2016 @09:40PM (#13053030)
That can work for statically-linked object files, but what about dynamically linked? You can load one with a function call, get back a function pointer, and invoke it like any other function. Trying to use some metadata would slow down the function call significantly, even if you tried to cache it somewhere.