-
Notifications
You must be signed in to change notification settings - Fork 120
Automated conversion from C to Rust #151
Comments
Interesting! I think the two things to do are
Do you have an idea of what a good first target would be? |
Hmmmm, seems like c2rust handles macros just fine. I wonder if we want to use it to process src/helpers.c instead of compiling that as a separate C object. Since helpers.c is a separate translation unit, calls to macros can't get inlined and get a bit slow. |
FWIW, calls across translation units are inlinable if we use LTO. |
Just wanted to pop over here to say we're definitely interested in making it easier to get c2rust working on kernel modules. We've translated one module so far, and things seems to work fairly well after we improved support for a bunch of gcc-isms. Automatically refactoring the initial output of c2rust to use your types and bindings ought to be fairly straightforward and might be a good path to better usability. |
Sorry for the noise, but were there any updates regarding this goal/blog post? |
We're still planning to put up a blog post on using C2Rust for a kernel module, hopefully in January. |
is there any update on the blogpost for c2rusting a kernel module? I'm really looking forward to it |
Not yet, but thanks for the reminder. It had to get pushed back a bit because of other things taking priority. However, definitely still going to happen, hopefully can write it soon! |
Which kernel module has been c 2 rust? Is it |
FWIW last time I checked Stacked borrows(rust's proposed aliasing rules): https://github.com/rust-lang/unsafe-code-guidelines/blob/master/wip/stacked-borrows.md EDIT: I think this is the right tracking issue: immunant/c2rust#301 |
Idea is to provide the framework for automated conversion using c2rust, as they do for the user-space programs.
Corresponding issue in c2rust itself: immunant/c2rust#150
The text was updated successfully, but these errors were encountered: