Skip to content

Make extra::bigint sane - #6822

Closed
Aatch wants to merge 1 commit into
rust-lang:incomingfrom
Aatch:bigint-make-sane
Closed

Make extra::bigint sane#6822
Aatch wants to merge 1 commit into
rust-lang:incomingfrom
Aatch:bigint-make-sane

Conversation

@Aatch

Copy link
Copy Markdown
Contributor

This removes all the #[inline(always)] attributes from the bigint module, all 112 of them... This was responsible for increasing the code size of the module by almost 100x and accounts for roughly 95% of the previous build time of libextra.

@brson

Copy link
Copy Markdown
Contributor

Nice find! 🌸 I wonder how much more we could get from removing other inline attributes.

bors added a commit that referenced this pull request May 30, 2013
This removes all the `#[inline(always)]` attributes from the bigint module, all 112 of them... This was responsible for increasing the code size of the module by almost 100x and accounts for roughly 95% of the previous build time of libextra.
@bstrie

Copy link
Copy Markdown
Contributor

@Aatch I agree with this change, but this doesn't leave a single #[inline] anywhere at all in the module. Is that correct? Do we not expect users of this code to desire cross-crate inlining at all?

@Aatch

Copy link
Copy Markdown
ContributorAuthor

@bstrie there has been talk of removing the module altogether. The motivation being that this has very few, if any, users. There are some functions that should probably be marked with #[inline] but I don't think this is going to severely affect many (if any) people. @pcwalton mentioned that until it's performant with GMP, it's not going to be used.

flip1995 pushed a commit to flip1995/rust that referenced this pull request Mar 11, 2021
Rustfmt version "Two"
changelog: none
This enables some ~bug fixes~ changes from rustfmt. This is more consistent with rustc's config, and should be more forward-compatible. Also, the changes look good IMO. 😃
U007D pushed a commit to U007D/rust-mos that referenced this pull request Aug 21, 2026
6822: Read version of rustc that compiled proc macro r=edwin0cheng a=jsomedon
Signed-off-by: Jay Somedon <jay.somedon@outlook.com>
This PR is to fixrust-lang#6174.
I basically
* added two methods, `read_version` and `read_section`(used by `read_version`)
* two new crates `snap` and `object` to be used by those two methods
I just noticed that some part of code were auto-reformatted by rust-analyzer on file save. Does it matter?
Co-authored-by: Jay Somedon <jay.somedon@outlook.com>
Co-authored-by: Edwin Cheng <edwin0cheng@gmail.com>
U007D pushed a commit to U007D/rust-mos that referenced this pull request Aug 21, 2026
8716: Replace `memmap` with `memmap2` in `proc_macro_api` r=edwin0cheng a=memoryruins
rust-lang#7522 did the same for `proc_macro_srv` before this usage of `memmap` was introduced to `proc_macro_api` in rust-lang#6822 .
Something like [`cargo-deny`](https://github.com/EmbarkStudios/cargo-deny-action) could help prevent specific crates (and versions, licenses, etc) from being introduced into the crate tree, but that's unrelated to this pull request.
Co-authored-by: memoryruins <memoryruinsmusic@gmail.com>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants

@Aatch@brson@bstrie@bors@pcwalton