Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

clang manages with "Do whatever gcc does" I wonder why that isn't good enough. Doing nothing useful now as we might want to do something more useful later than what we can now seems a bit self defeating, but I may be missing the point because I want to us inline assembly language in unsafe blocks.


The problem is, rust has stability guarantees to uphold. As such, depending on the unstable behavior of an upstream component is not possible in the stable branch of rust.

Furthermore, there are worries that depending on the llvm behavior might impede work on alternative rust backends, such as cretonne.


Clang isn't using LLVM's inline asm directly, it translates from the (stable) GCC format into the internal LLVM one. rustc could theoretically do the same translation, but implementing that is significantly more work than just stabilizing the current implementation of asm!().


That and GCC's format is not exactly great. I'm generally looking unfavorably towards NIH but in this instance I really hope they figure out something better.


GCC's format mostly exposes parts of GCC's internal machine description language (to the point that, in the past, most of it was documented only on the "GCC internals" part of the manual). It comes from a simpler time.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: