rust/compiler
bors 7a202a9056 Auto merge of #135204 - RalfJung:win64-zst, r=SparrowLii
fix handling of ZST in win64 ABI on windows-msvc targets

The Microsoft calling conventions do not really say anything about ZST since they do not seem to exist in MSVC. However, both GCC and clang allow passing ZST over  `__attribute__((ms_abi))` functions (which matches our `extern "win64" fn`) on `windows-gnu` targets, and therefore implicitly define a de-facto ABI for these types (and lucky enough they seem to define the same ABI). This ABI should be the same for windows-msvc and windows-gnu targets, so we use this as a hint for how to implement this ABI everywhere: we always pass ZST by-ref.

The best alternative would be to just reject compiling functions which cannot exist in MSVC, but that would be a breaking change.

Cc `@programmerjake` `@ChrisDenton`
Fixes https://github.com/rust-lang/rust/issues/132893
2025-01-13 13:05:53 +00:00
..
rustc switch jemalloc-sys back to tikv-jemalloc-sys, and update to 0.6.0 2024-12-03 08:56:33 +00:00
rustc_abi fix ZST handling for Windows ABIs on MSVC target 2025-01-10 12:16:49 +01:00
rustc_arena Add inherent versions of MaybeUninit methods for slices 2025-01-11 23:57:00 -05:00
rustc_ast Remove allocations from case-insensitive comparison to keywords 2025-01-11 12:39:44 -05:00
rustc_ast_ir Add sugar for &pin (const|mut) types 2024-10-07 11:15:04 -07:00
rustc_ast_lowering Rename PatKind::Lit to Expr 2025-01-08 07:34:59 +00:00
rustc_ast_passes update cfg(bootstrap) 2025-01-08 21:26:39 +01:00
rustc_ast_pretty Rename PatKind::Lit to Expr 2025-01-08 07:34:59 +00:00
rustc_attr_data_structures mir_transform: implement forced inlining 2025-01-10 18:37:54 +00:00
rustc_attr_parsing Re-export more rustc_span::symbol things from rustc_span. 2024-12-18 13:38:53 +11:00
rustc_baked_icu_data Delete the cfg(not(parallel)) serial compiler 2024-11-12 13:38:58 +00:00
rustc_borrowck Auto merge of #135402 - matthiaskrgr:rollup-cz7hs13, r=matthiaskrgr 2025-01-12 14:43:10 +00:00
rustc_builtin_macros Rollup merge of #134877 - DavisRayM:129966-format-string-help-message, r=estebank 2025-01-01 16:35:30 +11:00
rustc_codegen_cranelift Merge commit 'e39eacd2d4' into sync_cg_clif-2025-01-10 2025-01-10 09:02:07 +00:00
rustc_codegen_gcc migrate rustc_codegen_gcc to the DenseBitSet name 2025-01-11 11:34:03 +00:00
rustc_codegen_llvm Rollup merge of #135205 - lqd:bitsets, r=Mark-Simulacrum 2025-01-11 18:13:47 +01:00
rustc_codegen_ssa Rollup merge of #135205 - lqd:bitsets, r=Mark-Simulacrum 2025-01-11 18:13:47 +01:00
rustc_const_eval rename BitSet to DenseBitSet 2025-01-11 11:34:01 +00:00
rustc_data_structures De-abstract tagged pointer abstraction 2025-01-12 14:56:10 +00:00
rustc_driver Use tidy to sort crate attributes for all compiler crates. 2024-06-12 15:49:10 +10:00
rustc_driver_impl add deprecated and do nothing flag to options table 2025-01-06 15:38:02 +03:00
rustc_error_codes Rewrite the error-code docs for coverage attributes [E0788] 2024-12-25 19:23:48 +11:00
rustc_error_messages Convert some Into impls into From impls 2024-12-31 01:56:33 +00:00
rustc_errors Auto merge of #135402 - matthiaskrgr:rollup-cz7hs13, r=matthiaskrgr 2025-01-12 14:43:10 +00:00
rustc_expand Rollup merge of #135247 - tgross35:stdlib-sym-list, r=oli-obk 2025-01-09 09:05:09 +01:00
rustc_feature mir_transform: implement forced inlining 2025-01-10 18:37:54 +00:00
rustc_fluent_macro use tracked_path in rustc_fluent_macro 2024-10-19 22:32:38 +08:00
rustc_fs_util Couple of changes to make it easier to compile rustc for wasm 2024-09-26 19:51:14 +00:00
rustc_graphviz Reformat using the new identifier sorting from rustfmt 2024-09-22 19:11:29 -04:00
rustc_hir Auto merge of #135268 - pietroalbini:pa-bump-stage0, r=Mark-Simulacrum 2025-01-09 13:33:16 +00:00
rustc_hir_analysis Rollup merge of #135378 - compiler-errors:unnecessary-stashing, r=chenyukang 2025-01-12 12:07:58 +01:00
rustc_hir_pretty Rename PatKind::Lit to Expr 2025-01-08 07:34:59 +00:00
rustc_hir_typeck Rollup merge of #135407 - joshtriplett:more-clippy, r=compiler-errors 2025-01-12 23:09:00 +01:00
rustc_incremental turn hir::ItemKind::Fn into a named-field variant 2025-01-04 11:35:31 +01:00
rustc_index document the use-cases of DenseBitSet a bit more 2025-01-11 11:34:03 +00:00
rustc_index_macros update rustc_index_macros feature handling 2024-12-19 20:32:12 +03:00
rustc_infer Simplify declared_generic_bounds_from_env 2025-01-02 01:30:55 +00:00
rustc_interface Rollup merge of #134030 - folkertdev:min-fn-align, r=workingjubilee 2025-01-11 18:13:45 +01:00
rustc_lexer Add test to check unicode identifier version 2024-12-09 06:23:59 -08:00
rustc_lint Update unstable lint docs to include required feature attributes 2025-01-12 19:31:05 +05:30
rustc_lint_defs remove test_unstable_lint feature 2025-01-13 00:14:24 +05:30
rustc_llvm llvm: Ignore error value that is always false 2025-01-07 01:02:22 +00:00
rustc_log Avoid naming variables str 2025-01-07 14:30:02 +02:00
rustc_macros Avoid naming variables str 2025-01-07 14:30:02 +02:00
rustc_metadata rename BitSet to DenseBitSet 2025-01-11 11:34:01 +00:00
rustc_middle Auto merge of #135167 - mzacho:depth-limit-const-eval-query, r=oli-obk 2025-01-13 10:18:26 +00:00
rustc_mir_build review comments 2025-01-11 01:23:37 +00:00
rustc_mir_dataflow rename BitSet to DenseBitSet 2025-01-11 11:34:01 +00:00
rustc_mir_transform Rollup merge of #135377 - compiler-errors:impossible-step, r=oli-obk 2025-01-12 12:07:58 +01:00
rustc_monomorphize Rollup merge of #135314 - compiler-errors:eagerly-mono-closures, r=wesleywiser 2025-01-11 18:13:47 +01:00
rustc_next_trait_solver Implement const Destruct in old solver 2025-01-08 18:14:58 +00:00
rustc_parse Remove allocations from case-insensitive comparison to keywords 2025-01-11 12:39:44 -05:00
rustc_parse_format add suggestion for wrongly ordered format parameters 2024-12-30 06:14:26 -08:00
rustc_passes mir_transform: implement forced inlining 2025-01-10 18:37:54 +00:00
rustc_pattern_analysis rename BitSet to DenseBitSet 2025-01-11 11:34:01 +00:00
rustc_privacy turn hir::ItemKind::Fn into a named-field variant 2025-01-04 11:35:31 +01:00
rustc_query_impl don't return an Option from try_find_dep_kind 2025-01-07 21:57:00 +01:00
rustc_query_system don't return an Option from try_find_dep_kind 2025-01-07 21:57:00 +01:00
rustc_resolve Deny clippy:;four_forward_slashes and fix the only occurrence 2025-01-12 15:09:16 +02:00
rustc_sanitizers Eliminate an unnecessary Symbol::to_string; use as_str 2025-01-07 14:24:47 +02:00
rustc_serialize Fix explicit_iter_loop in rustc_serialize 2024-10-16 15:44:16 +02:00
rustc_session Rollup merge of #134030 - folkertdev:min-fn-align, r=workingjubilee 2025-01-11 18:13:45 +01:00
rustc_smir Auto merge of #134625 - compiler-errors:unsafe-binders-ty, r=oli-obk 2024-12-24 00:51:51 +00:00
rustc_span mir_transform: implement forced inlining 2025-01-10 18:37:54 +00:00
rustc_symbol_mangling Account for identity substituted items in symbol mangling 2025-01-09 13:55:40 +01:00
rustc_target on Windows, consistently pass ZST by-ref 2025-01-12 13:32:36 +01:00
rustc_trait_selection mir_transform: implement forced inlining 2025-01-10 18:37:54 +00:00
rustc_traits Delay a bug when encountering an impl with unconstrained generics in codegen_select 2024-11-23 05:27:45 +00:00
rustc_transmute add comment explaining why ty_and_layout_field is not used 2024-12-18 11:01:54 +01:00
rustc_ty_utils on Windows, consistently pass ZST by-ref 2025-01-12 13:32:36 +01:00
rustc_type_ir rename BitSet to DenseBitSet 2025-01-11 11:34:01 +00:00
rustc_type_ir_macros do not relate Abi and Safety 2024-10-22 23:13:04 +02:00
stable_mir make no-variant types a dedicated Variants variant 2024-12-18 11:01:54 +01:00