about summary refs log tree commit diff
path: root/compiler/rustc_codegen_gcc/src/allocator.rs
AgeCommit message (Collapse)AuthorLines
2025-08-04Merge commit '482e8540a1b757ed7bccc2041c5400f051fdb01e' into ↵Guillaume Gomez-5/+9
subtree-update_cg_gcc_2025-08-04
2025-07-03Make __rust_alloc_error_handler_should_panic a functionDaniel Paoliello-11/+33
2025-06-16Change __rust_no_alloc_shim_is_unstable to be a functionDaniel Paoliello-36/+42
2025-03-17Remove implicit #[no_mangle] for #[rustc_std_internal_symbol]bjorn3-6/+7
2025-01-13Merge commit '59a81c2ca1edc88ad3ac4b27a8e03977ffb8e73a' into ↵Antoni Boucher-11/+15
subtree-update_cg_gcc_2025_01_12
2024-10-01Replace -Z default-hidden-visibility with -Z default-visibilityDavid Lattimore-3/+10
MCP: https://github.com/rust-lang/compiler-team/issues/782 Co-authored-by: bjorn3 <17426603+bjorn3@users.noreply.github.com>
2024-09-22Reformat using the new identifier sorting from rustfmtMichael Goulet-2/+2
2024-03-05Merge commit 'b385428e3ddf330805241e7758e773f933357c4b' into ↵Guillaume Gomez-20/+42
subtree-update_cg_gcc_2024-03-05
2023-12-13Add unstable `-Zdefault-hidden-visibility` cmdline flag for `rustc`.Lukasz Anforowicz-1/+1
The new flag has been described in the Major Change Proposal at https://github.com/rust-lang/compiler-team/issues/656
2023-10-09Merge commit '11a0cceab966e5ff1058ddbcab5977e8a1d6d290' into ↵Antoni Boucher-59/+50
subtree-update_cg_gcc_2023-10-09
2023-08-06Generate better function argument names in global_allocator expansionDavid Tolnay-2/+2
2023-05-11Prevent insta-stable no alloc shim supportbjorn3-1/+6
You will need to add the following as replacement for the old __rust_* definitions when not using the alloc shim. #[no_mangle] static __rust_no_alloc_shim_is_unstable: u8 = 0;
2023-05-11Use global_fn_name instead of format!bjorn3-2/+3
2023-05-11Split AllocatorKind::fn_name in global_fn_name and default_fn_namebjorn3-2/+2
2023-05-11Don't use an allocator shim for `#[global_allocator]`bjorn3-58/+61
This makes it possible to use liballoc/libstd in combination with `--emit obj` if you use `#[global_allocator]`. Making it work for the default libstd allocator would require weak functions, which are not well supported on all systems.
2023-04-25Revert "Remove #[alloc_error_handler] from the compiler and library"Matthias Krüger-1/+33
This reverts commit abc0660118cc95f47445fd33502a11dd448f5968.
2023-04-16Remove #[alloc_error_handler] from the compiler and libraryAmanieu d'Antras-33/+1
2023-03-05Merge commit '08a6d6e16b5efe217123e780398969946266268f' into ↵Antoni Boucher-3/+13
sync-cg_gcc-2023-03-04
2022-10-31Rewrite implementation of `#[alloc_error_handler]`Amanieu d'Antras-9/+2
The new implementation doesn't use weak lang items and instead changes `#[alloc_error_handler]` to an attribute macro just like `#[global_allocator]`. The attribute will generate the `__rg_oom` function which is called by the compiler-generated `__rust_alloc_error_handler`. If no `__rg_oom` function is defined in any crate then the compiler shim will call `__rdl_oom` in the alloc crate which will simply panic. This also fixes link errors with `-C link-dead-code` with `default_alloc_error_handler`: `__rg_oom` was previously defined in the alloc crate and would attempt to reference the `oom` lang item, even if it didn't exist. This worked as long as `__rg_oom` was excluded from linking since it was not called. This is a prerequisite for the stabilization of `default_alloc_error_handler` (#102318).
2022-07-13Rename `debugging_opts` to `unstable_opts`Joshua Nelson-1/+1
This is no longer used only for debugging options (e.g. `-Zoutput-width`, `-Zallow-features`). Rename it to be more clear.
2022-03-03Add -Z oom={panic,abort} command-line optionAmanieu d'Antras-1/+8
2021-09-17Merge commit '48d60ab7c505c6c1ebb042eacaafd8dc9f7a9267' into libgccjit-codegenAntoni Boucher-1/+4
2021-08-15Merge commit 'e228f0c16ea8c34794a6285bf57aab627c26b147' into libgccjit-codegenAntoni Boucher-5/+3
2021-08-12Add 'compiler/rustc_codegen_gcc/' from commit ↵Antoni Boucher-0/+115
'afae271d5d3719eeb92c18bc004bb6d1965a5f3f' git-subtree-dir: compiler/rustc_codegen_gcc git-subtree-mainline: ae90dcf0207c57c3034f00b07048d63f8b2363c8 git-subtree-split: afae271d5d3719eeb92c18bc004bb6d1965a5f3f