projects/linux·commit b079329b

Merge tag 'rust-7.2' of gitolite.kernel.org:pub/scm/linux/kernel/git/ojeda/linux

b079329b · Linus Torvalds <[email protected]> · 2026-06-15 09:25:48 +05:30

Pull Rust updates from Miguel Ojeda:
 "This one is big due to the vendoring of the `zerocopy` library, which
  allows us to replace a bunch of `unsafe` code dealing with conversions
  between byte sequences and other types with safe alternatives. More
  details on that below (and in its merge commit).

  Toolchain and infrastructure:

   - Introduce support for the 'zerocopy' library [1][2]:

         Fast, safe, compile error. Pick two.

         Zerocopy makes zero-cost memory manipulation effortless. We write
         `unsafe` so you don't have to.

     It essentially provides derivable traits (e.g. 'FromBytes') and
     macros (e.g. 'transmute!') for safely converting between byte
     sequences and other types. Having such support allows us to remove
     some 'unsafe' code.

     It is among the most downloaded Rust crates and it is also used by
     the Rust compiler itself.

     It is licensed under "BSD-2-Clause OR Apache-2.0 OR MIT".

     The crates are imported essentially as-is (only +2/-3 lines needed
     to be adapted), plus SPDX identifiers. Upstream has since added the
     SPDX identifiers as well as one of the tweaks at my request, thus
     reducing our future diffs on updates -- I keep the details in one
     of our usual live lists [3].

     In total, it is about ~39k lines added, ~32k without counting
     'benches/' which are just for documentation purposes.

     The series includes a few Kbuild and rust-analyzer improvements and
     an example patch using it in Nova, removing one 'unsafe impl'.

     I checked that the codegen of an isolated example function (similar
     to the Nova patch on top) is essentially identical. It also turns
     out that (for that particular case) the 'zerocopy' version, even
     with 'debug-assertions' enabled, has no remaining panics, unlike a
     few in the current code (since the compiler can prove the remaining
     'ub_checks' statically).

     So their "fast, safe" does indeed check out -- at least in that
     case.

   - Support AutoFDO. This allows Rust code to be profiled and optimized
     based on the profile. Tested with Rust Binder: ~13% slower without
     AutoFDO in the binderAddInts benchmark (using an app-launch
     benchmark for the profile).

   - Support Software Tag-Based KASAN.

     In addition, fix KASAN Kconfig by requiring Clang.

   - Add Kconfig options for each existing Rust KUnit test suite, such
     as 'CONFIG_RUST_BITMAP_KUNIT_TEST'.

     They are placed within a new menu, 'CONFIG_RUST_KUNIT_TESTS', in
     the new 'rust/kernel/Kconfig.test' file.

   - Support the upcoming Rust 1.98.0 release (expected 2026-08-20):
     lint cleanups and an unstable flag rename.

   - Disable 'rustdoc' documentation inlining for all prelude items,
     which bloats the generated documentation.

   - Ignore (in Git) and clean (in Kbuild) the (rarely) 'rustc'-generated
     '*.long-type-*.txt' files.

  'kernel' crate:

   - Add new 'bitfield' module with the 'bitfield!' macro (extracted
     from the existing 'register!' one), which declares integer types
     that are split into distinct bit fields of arbitrary length.

     Each field is a 'Bounded' of the appropriate bit width (ensuring
     values are properly validated and avoiding implicit data loss) and
     gets several generated getters and setters (infallible, 'const' and
     fallible) as well as associated constants ('_MASK', '_SHIFT' and
     '_RANGE'). It also supports fields that can be converted from/to
     custom types, either fallibly ('?=>') or infallibly ('=>').

     For instance:

         bitfield! {
             struct Rgb(u16) {
                 15:11 blue;
                 10:5 green;
                 4:0 red;
             }
         }

         // Compile-time checks.
         let color = Rgb::zeroed().with_const_green::<0x1f>();

         assert_eq!(color.green(), 0x1f);
         assert_eq!(color.into_raw(), 0x1f << Rgb::GREEN_SHIFT);

     Add as well documentation and a test suite for it, as usual; and
     update the 'register!' macro to use it.

     It will be maintained by Alexandre Courbot (with Yury Norov as
     reviewer) under a new 'MAINTAINERS' entry: 'RUST [BITFIELD]'.

   - 'ptr' module: rework index projection syntax into keyworded syntax
     and introduce panicking variant.

     The keyword syntax ('build:', 'try:', 'panic:') is more explicit
     and paves the way of perhaps adding more flavors in the future,
     e.g. an 'unsafe' index projection.

     For instance, projections now look like this:

         fn f(p: *const [u8; 32]) -> Result {
             // Ok, within bounds, checked at build time.
             project!(p, [build: 1]);

             // Build error.
             project!(p, [build: 128]);

             // `OutOfBound` runtime error (convertible to `ERANGE`).
             project!(p, [try: 128]);

             // Runtime panic.
             project!(p, [panic: 128]);

             Ok(())
         }

     Update as well the users, which now look like e.g.

         // Pointer to the first entry of the GSP message queue.
         let data = project!(self.0.as_ptr(), .gspq.msgq.data[build: 0]);

   - 'build_assert' module: make the module the home of its macros
     instead of rendering them twice.

   - 'sync' module: add 'UniqueArc::as_ptr()' associated function.

   - 'alloc' module:

       - Fix the 'Vec::reserve()' doctest to properly account for the
         existing vector length in the capacity assertion.

       - Fix an incorrect operator in the 'Vec::extend_with()' 'SAFETY'
         comment; add a doc test demonstrating basic usage and the
         zero-length case.

   - Clean imports across several modules to follow the "kernel
     vertical" import style in order to minimize conflicts.

  'pin-init' crate:

   - User visible changes:

       - Do not generate 'non_snake_case' warnings for identifiers that
         are syntactically just users of a field name. This would allow
         all '#[allow(non_snake_case)]' in nova-core to be removed,
         which Gary will send to the nova tree next cycle.

       - Filter non-cfg attributes out properly in derived structs. This
         improves pin-init compatibility with other derive macros.

       - Insert projection types' where clause properly.

   - Other changes:

       - Bump MSRV to 1.82, plus associated cleanups.

       - Overhaul how init slots are projected. The new approach is
         easier to justify with safety comments.

       - Mark more functions as inline, which should help mitigate the
         super-long symbol name issue due to lack of inlining.

  rust-analyzer:

   - Support '--envs' for passing env vars for crates like 'zerocopy'.

  'MAINTAINERS':

   - Add the following reviewers to the 'RUST' entry:
       - Daniel Almeida
       - Tamir Duberstein
       - Alexandre Courbot
       - Onur Özkan

     They have been involved in the Rust for Linux project for about 7
     collective years and bring expertise across several domains, which
     will be very useful to have around in the future.

     Thanks everyone for stepping up!

  And some other fixes, cleanups and improvements"

Link: https://github.com/google/zerocopy [1]
Link: https://docs.rs/zerocopy [2]
Link: https://github.com/Rust-for-Linux/linux/issues/1239 [3]

* tag 'rust-7.2' of gitolite.kernel.org:pub/scm/linux/kernel/git/ojeda/linux: (86 commits)
  MAINTAINERS: add Onur Özkan as Rust reviewer
  MAINTAINERS: add Alexandre Courbot as Rust reviewer
  MAINTAINERS: add Tamir Duberstein as Rust reviewer
  MAINTAINERS: add Daniel Almeida as Rust reviewer
  kbuild: rust: clean `zerocopy-derive` in `mrproper`
  rust: make `build_assert` module the home of related macros
  rust: str: clean unused import for Rust >= 1.98
  rust: str: use the "kernel vertical" imports style
  rust: aref: use the "kernel vertical" imports style
  rust: page: use the "kernel vertical" imports style
  gpu: nova-core: firmware: parse `FalconUCodeDescV2` via `zerocopy`
  rust: prelude: add `zerocopy{,_derive}::FromBytes`
  rust: zerocopy-derive: enable support in kbuild
  rust: zerocopy-derive: add `README.md`
  rust: zerocopy-derive: avoid generating non-ASCII identifiers
  rust: zerocopy-derive: add SPDX License Identifiers
  rust: zerocopy-derive: import crate
  rust: zerocopy: enable support in kbuild
  rust: zerocopy: add `README.md`
  rust: zerocopy: remove float `Display` support
  ...
Commit
b079329b8691768962aa514b8f8c9077ca352459
Parents
b8b67474 · 48b375e4

Merge commit. Changes below are compared with the first parent: b8b67474.

Changes

310 files changed · +40553 −841

FileStatusAddDelContent
.gitignoremodified+3−0View file
Documentation/rust/testing.rstmodified+5−0View file
MAINTAINERSmodified+11−0View file
Makefilemodified+5−1View file
drivers/gpu/nova-core/bitfield.rsmodified+2−2View file
drivers/gpu/nova-core/firmware.rsmodified+1−4View file
drivers/gpu/nova-core/gsp/cmdq.rsmodified+3−3View file
drivers/gpu/nova-core/num.rsmodified+1−1View file
drivers/gpu/nova-core/vbios.rsmodified+4−2View file
init/Kconfigmodified+4−1View file
rust/Makefilemodified+81−15View file
rust/kernel/Kconfig.testadded+86−0View file
rust/kernel/alloc.rsmodified+6−2View file
rust/kernel/alloc/allocator.rsmodified+25−10View file
rust/kernel/alloc/allocator/iter.rsmodified+6−2View file
rust/kernel/alloc/kbox.rsmodified+54−24View file
rust/kernel/alloc/kvec.rsmodified+64−18View file
rust/kernel/alloc/kvec/errors.rsmodified+4−2View file
rust/kernel/alloc/layout.rsmodified+8−2View file
rust/kernel/bitfield.rsadded+862−0View file
rust/kernel/bitmap.rsmodified+2−3View file
rust/kernel/build_assert.rsmodified+12−7View file
rust/kernel/cpufreq.rsmodified+1−1View file
rust/kernel/dma.rsmodified+6−9View file
rust/kernel/error.rsmodified+2−4View file
rust/kernel/fmt.rsmodified+17−2View file
rust/kernel/init.rsmodified+2−0View file
rust/kernel/io/register.rsmodified+14−251View file
rust/kernel/io/resource.rsmodified+1−1View file
rust/kernel/ioctl.rsmodified+1−1View file
rust/kernel/kunit.rsmodified+1−0View file
rust/kernel/lib.rsmodified+1−0View file
rust/kernel/net/phy/reg.rsmodified+5−3View file
rust/kernel/num/bounded.rsmodified+1−1View file
rust/kernel/page.rsmodified+13−5View file
rust/kernel/prelude.rsmodified+15−4View file
rust/kernel/ptr/projection.rsmodified+80−19View file
rust/kernel/str.rsmodified+19−5View file
rust/kernel/sync/arc.rsmodified+12−0View file
rust/kernel/sync/aref.rsmodified+6−1View file
rust/kernel/sync/atomic/internal.rsmodified+6−3View file
rust/kernel/sync/atomic/predefine.rsmodified+3−6View file
rust/kernel/sync/lock/global.rsmodified+2−0View file
rust/kernel/sync/locked_by.rsmodified+1−1View file
rust/kernel/sync/refcount.rsmodified+5−3View file
rust/kernel/xarray.rsmodified+8−2View file
rust/pin-init/README.mdmodified+1−1View file
rust/pin-init/examples/big_struct_in_place.rsmodified+0−3View file
rust/pin-init/examples/error.rsmodified+2−0View file
rust/pin-init/examples/linked_list.rsmodified+0−2View file
rust/pin-init/examples/mutex.rsmodified+1−3View file
rust/pin-init/examples/pthread_mutex.rsmodified+1−3View file
rust/pin-init/examples/static_init.rsmodified+1−3View file
rust/pin-init/internal/src/diagnostics.rsmodified+14−0View file
rust/pin-init/internal/src/init.rsmodified+67−102View file
rust/pin-init/internal/src/lib.rsmodified+0−1View file
rust/pin-init/internal/src/pin_data.rsmodified+122−146View file
rust/pin-init/internal/src/zeroable.rsmodified+1−1View file
rust/pin-init/src/__internal.rsmodified+156−75View file
rust/pin-init/src/lib.rsmodified+73−64View file
rust/zerocopy-derive/README.mdadded+14−0View file
rust/zerocopy-derive/derive/from_bytes.rsadded+192−0View file
rust/zerocopy-derive/derive/into_bytes.rsadded+164−0View file
rust/zerocopy-derive/derive/known_layout.rsadded+350−0View file
rust/zerocopy-derive/derive/mod.rsadded+132−0View file
rust/zerocopy-derive/derive/try_from_bytes.rsadded+765−0View file
rust/zerocopy-derive/derive/unaligned.rsadded+80−0View file
rust/zerocopy-derive/lib.rsadded+146−0View file
rust/zerocopy-derive/repr.rsadded+851−0View file
rust/zerocopy-derive/util.rsadded+845−0View file
rust/zerocopy/README.mdadded+14−0View file
rust/zerocopy/benches/as_bytes_dynamic_size.rsadded+9−0View file
rust/zerocopy/benches/as_bytes_dynamic_size.x86-64added+5−0View file
rust/zerocopy/benches/as_bytes_dynamic_size.x86-64.mcaadded+47−0View file
rust/zerocopy/benches/as_bytes_static_size.rsadded+9−0View file
rust/zerocopy/benches/as_bytes_static_size.x86-64added+4−0View file
rust/zerocopy/benches/as_bytes_static_size.x86-64.mcaadded+45−0View file
rust/zerocopy/benches/extend_vec_zeroed.rsadded+9−0View file
rust/zerocopy/benches/extend_vec_zeroed.x86-64added+60−0View file
rust/zerocopy/benches/extend_vec_zeroed.x86-64.mcaadded+147−0View file
rust/zerocopy/benches/formats/coco_dynamic_padding.rsadded+24−0View file
rust/zerocopy/benches/formats/coco_dynamic_size.rsadded+27−0View file
rust/zerocopy/benches/formats/coco_static_size.rsadded+27−0View file
rust/zerocopy/benches/insert_vec_zeroed.rsadded+13−0View file
rust/zerocopy/benches/insert_vec_zeroed.x86-64added+79−0View file
rust/zerocopy/benches/insert_vec_zeroed.x86-64.mcaadded+183−0View file
rust/zerocopy/benches/new_box_zeroed.rsadded+9−0View file
rust/zerocopy/benches/new_box_zeroed.x86-64added+7−0View file
rust/zerocopy/benches/new_box_zeroed.x86-64.mcaadded+51−0View file
rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_padding.rsadded+11−0View file
rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_padding.x86-64added+24−0View file
rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_padding.x86-64.mcaadded+81−0View file
rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_size.rsadded+9−0View file
rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_size.x86-64added+22−0View file
rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_size.x86-64.mcaadded+77−0View file
rust/zerocopy/benches/new_vec_zeroed.rsadded+9−0View file
rust/zerocopy/benches/new_vec_zeroed.x86-64added+40−0View file
rust/zerocopy/benches/new_vec_zeroed.x86-64.mcaadded+113−0View file
rust/zerocopy/benches/new_zeroed.rsadded+9−0View file
rust/zerocopy/benches/new_zeroed.x86-64added+3−0View file
rust/zerocopy/benches/new_zeroed.x86-64.mcaadded+43−0View file
rust/zerocopy/benches/read_from_bytes.rsadded+7−0View file
rust/zerocopy/benches/read_from_bytes.x86-64added+15−0View file
rust/zerocopy/benches/read_from_bytes.x86-64.mcaadded+65−0View file
rust/zerocopy/benches/read_from_prefix.rsadded+10−0View file
rust/zerocopy/benches/read_from_prefix.x86-64added+14−0View file
rust/zerocopy/benches/read_from_prefix.x86-64.mcaadded+63−0View file
rust/zerocopy/benches/read_from_suffix.rsadded+10−0View file
rust/zerocopy/benches/read_from_suffix.x86-64added+15−0View file
rust/zerocopy/benches/read_from_suffix.x86-64.mcaadded+65−0View file
rust/zerocopy/benches/ref_from_bytes_dynamic_padding.rsadded+7−0View file
rust/zerocopy/benches/ref_from_bytes_dynamic_padding.x86-64added+22−0View file
rust/zerocopy/benches/ref_from_bytes_dynamic_padding.x86-64.mcaadded+77−0View file
rust/zerocopy/benches/ref_from_bytes_dynamic_size.rsadded+7−0View file
rust/zerocopy/benches/ref_from_bytes_dynamic_size.x86-64added+20−0View file
rust/zerocopy/benches/ref_from_bytes_dynamic_size.x86-64.mcaadded+75−0View file
rust/zerocopy/benches/ref_from_bytes_static_size.rsadded+7−0View file
rust/zerocopy/benches/ref_from_bytes_static_size.x86-64added+8−0View file
rust/zerocopy/benches/ref_from_bytes_static_size.x86-64.mcaadded+53−0View file
rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_padding.rsadded+10−0View file
rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_padding.x86-64added+19−0View file
rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_padding.x86-64.mcaadded+71−0View file
rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_size.rsadded+10−0View file
rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_size.x86-64added+16−0View file
rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_size.x86-64.mcaadded+65−0View file
rust/zerocopy/benches/ref_from_prefix_dynamic_padding.rsadded+10−0View file
rust/zerocopy/benches/ref_from_prefix_dynamic_padding.x86-64added+22−0View file
rust/zerocopy/benches/ref_from_prefix_dynamic_padding.x86-64.mcaadded+77−0View file
rust/zerocopy/benches/ref_from_prefix_dynamic_size.rsadded+10−0View file
rust/zerocopy/benches/ref_from_prefix_dynamic_size.x86-64added+17−0View file
rust/zerocopy/benches/ref_from_prefix_dynamic_size.x86-64.mcaadded+67−0View file
rust/zerocopy/benches/ref_from_prefix_static_size.rsadded+10−0View file
rust/zerocopy/benches/ref_from_prefix_static_size.x86-64added+8−0View file
rust/zerocopy/benches/ref_from_prefix_static_size.x86-64.mcaadded+53−0View file
rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_padding.rsadded+13−0View file
rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_padding.x86-64added+26−0View file
rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_padding.x86-64.mcaadded+85−0View file
rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_size.rsadded+13−0View file
rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_size.x86-64added+22−0View file
rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_size.x86-64.mcaadded+77−0View file
rust/zerocopy/benches/ref_from_suffix_dynamic_padding.rsadded+10−0View file
rust/zerocopy/benches/ref_from_suffix_dynamic_padding.x86-64added+23−0View file
rust/zerocopy/benches/ref_from_suffix_dynamic_padding.x86-64.mcaadded+79−0View file
rust/zerocopy/benches/ref_from_suffix_dynamic_size.rsadded+10−0View file
rust/zerocopy/benches/ref_from_suffix_dynamic_size.x86-64added+13−0View file
rust/zerocopy/benches/ref_from_suffix_dynamic_size.x86-64.mcaadded+63−0View file
rust/zerocopy/benches/ref_from_suffix_static_size.rsadded+10−0View file
rust/zerocopy/benches/ref_from_suffix_static_size.x86-64added+13−0View file
rust/zerocopy/benches/ref_from_suffix_static_size.x86-64.mcaadded+61−0View file
rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_padding.rsadded+13−0View file
rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_padding.x86-64added+27−0View file
rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_padding.x86-64.mcaadded+85−0View file
rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_size.rsadded+13−0View file
rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_size.x86-64added+23−0View file
rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_size.x86-64.mcaadded+77−0View file
rust/zerocopy/benches/split_at_dynamic_padding.rsadded+12−0View file
rust/zerocopy/benches/split_at_dynamic_padding.x86-64added+12−0View file
rust/zerocopy/benches/split_at_dynamic_padding.x86-64.mcaadded+59−0View file
rust/zerocopy/benches/split_at_dynamic_size.rsadded+12−0View file
rust/zerocopy/benches/split_at_dynamic_size.x86-64added+12−0View file
rust/zerocopy/benches/split_at_dynamic_size.x86-64.mcaadded+59−0View file
rust/zerocopy/benches/split_at_unchecked_dynamic_padding.rsadded+12−0View file
rust/zerocopy/benches/split_at_unchecked_dynamic_padding.x86-64added+6−0View file
rust/zerocopy/benches/split_at_unchecked_dynamic_padding.x86-64.mcaadded+49−0View file
rust/zerocopy/benches/split_at_unchecked_dynamic_size.rsadded+12−0View file
rust/zerocopy/benches/split_at_unchecked_dynamic_size.x86-64added+6−0View file
rust/zerocopy/benches/split_at_unchecked_dynamic_size.x86-64.mcaadded+49−0View file
rust/zerocopy/benches/split_via_immutable_dynamic_padding.rsadded+11−0View file
rust/zerocopy/benches/split_via_immutable_dynamic_padding.x86-64added+14−0View file
rust/zerocopy/benches/split_via_immutable_dynamic_padding.x86-64.mcaadded+65−0View file
rust/zerocopy/benches/split_via_immutable_dynamic_size.rsadded+11−0View file
rust/zerocopy/benches/split_via_immutable_dynamic_size.x86-64added+13−0View file
rust/zerocopy/benches/split_via_immutable_dynamic_size.x86-64.mcaadded+63−0View file
rust/zerocopy/benches/split_via_runtime_check_dynamic_padding.rsadded+11−0View file
rust/zerocopy/benches/split_via_runtime_check_dynamic_padding.x86-64added+22−0View file
rust/zerocopy/benches/split_via_runtime_check_dynamic_padding.x86-64.mcaadded+79−0View file
rust/zerocopy/benches/split_via_runtime_check_dynamic_size.rsadded+11−0View file
rust/zerocopy/benches/split_via_runtime_check_dynamic_size.x86-64added+13−0View file
rust/zerocopy/benches/split_via_runtime_check_dynamic_size.x86-64.mcaadded+63−0View file
rust/zerocopy/benches/split_via_unchecked_dynamic_padding.rsadded+11−0View file
rust/zerocopy/benches/split_via_unchecked_dynamic_padding.x86-64added+14−0View file
rust/zerocopy/benches/split_via_unchecked_dynamic_padding.x86-64.mcaadded+65−0View file
rust/zerocopy/benches/split_via_unchecked_dynamic_size.rsadded+11−0View file
rust/zerocopy/benches/split_via_unchecked_dynamic_size.x86-64added+13−0View file
rust/zerocopy/benches/split_via_unchecked_dynamic_size.x86-64.mcaadded+63−0View file
rust/zerocopy/benches/transmute.rsadded+16−0View file
rust/zerocopy/benches/transmute.x86-64added+3−0View file
rust/zerocopy/benches/transmute.x86-64.mcaadded+43−0View file
rust/zerocopy/benches/transmute_ref_dynamic_size.rsadded+16−0View file
rust/zerocopy/benches/transmute_ref_dynamic_size.x86-64added+4−0View file
rust/zerocopy/benches/transmute_ref_dynamic_size.x86-64.mcaadded+45−0View file
rust/zerocopy/benches/transmute_ref_static_size.rsadded+15−0View file
rust/zerocopy/benches/transmute_ref_static_size.x86-64added+3−0View file
rust/zerocopy/benches/transmute_ref_static_size.x86-64.mcaadded+43−0View file
rust/zerocopy/benches/try_read_from_bytes.rsadded+7−0View file
rust/zerocopy/benches/try_read_from_bytes.x86-64added+23−0View file
rust/zerocopy/benches/try_read_from_bytes.x86-64.mcaadded+79−0View file
rust/zerocopy/benches/try_read_from_prefix.rsadded+10−0View file
rust/zerocopy/benches/try_read_from_prefix.x86-64added+16−0View file
rust/zerocopy/benches/try_read_from_prefix.x86-64.mcaadded+67−0View file
rust/zerocopy/benches/try_read_from_suffix.rsadded+10−0View file
rust/zerocopy/benches/try_read_from_suffix.x86-64added+18−0View file
rust/zerocopy/benches/try_read_from_suffix.x86-64.mcaadded+71−0View file
rust/zerocopy/benches/try_ref_from_bytes_dynamic_padding.rsadded+7−0View file
rust/zerocopy/benches/try_ref_from_bytes_dynamic_padding.x86-64added+24−0View file
rust/zerocopy/benches/try_ref_from_bytes_dynamic_padding.x86-64.mcaadded+81−0View file
rust/zerocopy/benches/try_ref_from_bytes_dynamic_size.rsadded+7−0View file
rust/zerocopy/benches/try_ref_from_bytes_dynamic_size.x86-64added+22−0View file
rust/zerocopy/benches/try_ref_from_bytes_dynamic_size.x86-64.mcaadded+79−0View file
rust/zerocopy/benches/try_ref_from_bytes_static_size.rsadded+7−0View file
rust/zerocopy/benches/try_ref_from_bytes_static_size.x86-64added+13−0View file
rust/zerocopy/benches/try_ref_from_bytes_static_size.x86-64.mcaadded+59−0View file
rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_padding.rsadded+10−0View file
rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_padding.x86-64added+21−0View file
rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_padding.x86-64.mcaadded+75−0View file
rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_size.rsadded+10−0View file
rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_size.x86-64added+18−0View file
rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_size.x86-64.mcaadded+69−0View file
rust/zerocopy/benches/try_ref_from_prefix_dynamic_padding.rsadded+10−0View file
rust/zerocopy/benches/try_ref_from_prefix_dynamic_padding.x86-64added+29−0View file
rust/zerocopy/benches/try_ref_from_prefix_dynamic_padding.x86-64.mcaadded+91−0View file
rust/zerocopy/benches/try_ref_from_prefix_dynamic_size.rsadded+10−0View file
rust/zerocopy/benches/try_ref_from_prefix_dynamic_size.x86-64added+22−0View file
rust/zerocopy/benches/try_ref_from_prefix_dynamic_size.x86-64.mcaadded+77−0View file
rust/zerocopy/benches/try_ref_from_prefix_static_size.rsadded+10−0View file
rust/zerocopy/benches/try_ref_from_prefix_static_size.x86-64added+15−0View file
rust/zerocopy/benches/try_ref_from_prefix_static_size.x86-64.mcaadded+63−0View file
rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_padding.rsadded+13−0View file
rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_padding.x86-64added+30−0View file
rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_padding.x86-64.mcaadded+91−0View file
rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_size.rsadded+13−0View file
rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_size.x86-64added+26−0View file
rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_size.x86-64.mcaadded+83−0View file
rust/zerocopy/benches/try_ref_from_suffix_dynamic_padding.rsadded+10−0View file
rust/zerocopy/benches/try_ref_from_suffix_dynamic_padding.x86-64added+26−0View file
rust/zerocopy/benches/try_ref_from_suffix_dynamic_padding.x86-64.mcaadded+85−0View file
rust/zerocopy/benches/try_ref_from_suffix_dynamic_size.rsadded+10−0View file
rust/zerocopy/benches/try_ref_from_suffix_dynamic_size.x86-64added+18−0View file
rust/zerocopy/benches/try_ref_from_suffix_dynamic_size.x86-64.mcaadded+71−0View file
rust/zerocopy/benches/try_ref_from_suffix_static_size.rsadded+10−0View file
rust/zerocopy/benches/try_ref_from_suffix_static_size.x86-64added+16−0View file
rust/zerocopy/benches/try_ref_from_suffix_static_size.x86-64.mcaadded+67−0View file
rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_padding.rsadded+13−0View file
rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_padding.x86-64added+32−0View file
rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_padding.x86-64.mcaadded+95−0View file
rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_size.rsadded+13−0View file
rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_size.x86-64added+28−0View file
rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_size.x86-64.mcaadded+87−0View file
rust/zerocopy/benches/try_transmute.rsadded+16−0View file
rust/zerocopy/benches/try_transmute.x86-64added+9−0View file
rust/zerocopy/benches/try_transmute.x86-64.mcaadded+55−0View file
rust/zerocopy/benches/try_transmute_ref_dynamic_size.rsadded+18−0View file
rust/zerocopy/benches/try_transmute_ref_dynamic_size.x86-64added+6−0View file
rust/zerocopy/benches/try_transmute_ref_dynamic_size.x86-64.mcaadded+49−0View file
rust/zerocopy/benches/try_transmute_ref_static_size.rsadded+17−0View file
rust/zerocopy/benches/try_transmute_ref_static_size.x86-64added+5−0View file
rust/zerocopy/benches/try_transmute_ref_static_size.x86-64.mcaadded+47−0View file
rust/zerocopy/benches/write_to_dynamic_size.rsadded+9−0View file
rust/zerocopy/benches/write_to_dynamic_size.x86-64added+21−0View file
rust/zerocopy/benches/write_to_dynamic_size.x86-64.mcaadded+77−0View file
rust/zerocopy/benches/write_to_prefix_dynamic_size.rsadded+12−0View file
rust/zerocopy/benches/write_to_prefix_dynamic_size.x86-64added+21−0View file
rust/zerocopy/benches/write_to_prefix_dynamic_size.x86-64.mcaadded+77−0View file
rust/zerocopy/benches/write_to_prefix_static_size.rsadded+12−0View file
rust/zerocopy/benches/write_to_prefix_static_size.x86-64added+11−0View file
rust/zerocopy/benches/write_to_prefix_static_size.x86-64.mcaadded+57−0View file
rust/zerocopy/benches/write_to_static_size.rsadded+9−0View file
rust/zerocopy/benches/write_to_static_size.x86-64added+11−0View file
rust/zerocopy/benches/write_to_static_size.x86-64.mcaadded+57−0View file
rust/zerocopy/benches/write_to_suffix_dynamic_size.rsadded+12−0View file
rust/zerocopy/benches/write_to_suffix_dynamic_size.x86-64added+22−0View file
rust/zerocopy/benches/write_to_suffix_dynamic_size.x86-64.mcaadded+79−0View file
rust/zerocopy/benches/write_to_suffix_static_size.rsadded+12−0View file
rust/zerocopy/benches/write_to_suffix_static_size.x86-64added+11−0View file
rust/zerocopy/benches/write_to_suffix_static_size.x86-64.mcaadded+57−0View file
rust/zerocopy/benches/zero_dynamic_padding.rsadded+9−0View file
rust/zerocopy/benches/zero_dynamic_padding.x86-64added+7−0View file
rust/zerocopy/benches/zero_dynamic_padding.x86-64.mcaadded+51−0View file
rust/zerocopy/benches/zero_dynamic_size.rsadded+9−0View file
rust/zerocopy/benches/zero_dynamic_size.x86-64added+5−0View file
rust/zerocopy/benches/zero_dynamic_size.x86-64.mcaadded+47−0View file
rust/zerocopy/benches/zero_static_size.rsadded+9−0View file
rust/zerocopy/benches/zero_static_size.x86-64added+4−0View file
rust/zerocopy/benches/zero_static_size.x86-64.mcaadded+45−0View file
rust/zerocopy/rustdoc/style.cssadded+57−0View file
rust/zerocopy/src/byte_slice.rsadded+434−0View file
rust/zerocopy/src/byteorder.rsadded+1564−0View file
rust/zerocopy/src/deprecated.rsadded+281−0View file
rust/zerocopy/src/error.rsadded+1350−0View file
rust/zerocopy/src/impls.rsadded+2389−0View file
rust/zerocopy/src/layout.rsadded+2225−0View file
rust/zerocopy/src/lib.rsadded+7612−0View file
rust/zerocopy/src/macros.rsadded+1825−0View file
rust/zerocopy/src/pointer/inner.rsadded+754−0View file
rust/zerocopy/src/pointer/invariant.rsadded+298−0View file
rust/zerocopy/src/pointer/mod.rsadded+410−0View file
rust/zerocopy/src/pointer/ptr.rsadded+1586−0View file
rust/zerocopy/src/pointer/transmute.rsadded+522−0View file
rust/zerocopy/src/ref.rsadded+1358−0View file
rust/zerocopy/src/split_at.rsadded+1090−0View file
rust/zerocopy/src/util/macro_util.rsadded+1310−0View file
rust/zerocopy/src/util/macros.rsadded+1067−0View file
rust/zerocopy/src/util/mod.rsadded+938−0View file
rust/zerocopy/src/wrappers.rsadded+1034−0View file
samples/rust/rust_dma.rsmodified+5−7View file
scripts/Makefile.autofdomodified+5−1View file
scripts/Makefile.buildmodified+1−0View file
scripts/Makefile.kasanmodified+0−2View file
scripts/Makefile.libmodified+3−0View file
scripts/generate_rust_analyzer.pymodified+32−6View file

Only the first 600 diff lines are shown. Download the complete patch.

.gitignore

View file
diff --git a/.gitignore b/.gitignore
index 1cc34c9..38365b8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -188,5 +188,8 @@ sphinx_*/
# Rust analyzer configuration
/rust-project.json
+# rustc error message long types
+*.long-type-*.txt
+
# bc language scripts (not LLVM bitcode)
!kernel/time/timeconst.bc

Documentation/rust/testing.rst

View file
diff --git a/Documentation/rust/testing.rst b/Documentation/rust/testing.rst
index f43cb77..e3943ac 100644
--- a/Documentation/rust/testing.rst
+++ b/Documentation/rust/testing.rst
@@ -140,11 +140,15 @@ are also mapped to KUnit.
These tests are introduced by the ``kunit_tests`` procedural macro, which takes
the name of the test suite as an argument.
+Each test suite should be guarded by a Kconfig option in
+``rust/kernel/Kconfig.test``.
+
For instance, assume we want to test the function ``f`` from the documentation
tests section. We could write, in the same file where we have our function:
.. code-block:: rust
+ #[cfg(CONFIG_RUST_MYMOD_KUNIT_TEST)]
#[kunit_tests(rust_kernel_mymod)]
mod tests {
use super::*;
@@ -173,6 +177,7 @@ the unit type ``()``) or ``Result`` (i.e. any ``Result<T, E>``). For instance:
.. code-block:: rust
+ #[cfg(CONFIG_RUST_MYMOD_KUNIT_TEST)]
#[kunit_tests(rust_kernel_mymod)]
mod tests {
use super::*;

MAINTAINERS

View file
diff --git a/MAINTAINERS b/MAINTAINERS
index 0d94420..8c07f13 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -23400,6 +23400,10 @@ R: Andreas Hindborg <[email protected]>
R: Alice Ryhl <[email protected]>
R: Trevor Gross <[email protected]>
R: Danilo Krummrich <[email protected]>
+R: Daniel Almeida <[email protected]>
+R: Tamir Duberstein <[email protected]>
+R: Alexandre Courbot <[email protected]>
+R: Onur Özkan <[email protected]>
S: Supported
W: https://rust-for-linux.com
@@ -23429,6 +23433,13 @@ T: git https://github.com/Rust-for-Linux/linux.git alloc-next
F: rust/kernel/alloc.rs
F: rust/kernel/alloc/
+RUST [BITFIELD]
+M: Alexandre Courbot <[email protected]>
+R: Yury Norov <[email protected]>
+S: Maintained
+F: rust/kernel/bitfield.rs
+
RUST [INTEROP]
M: Joel Fernandes <[email protected]>
M: Alexandre Courbot <[email protected]>

Makefile

View file
diff --git a/Makefile b/Makefile
index 8fa944e..5e73bba 100644
--- a/Makefile
+++ b/Makefile
@@ -1709,7 +1709,8 @@ MRPROPER_FILES += include/config include/generated \
vmlinux-gdb.py \
rpmbuild \
rust/libmacros.so rust/libmacros.dylib \
- rust/libpin_init_internal.so rust/libpin_init_internal.dylib
+ rust/libpin_init_internal.so rust/libpin_init_internal.dylib \
+ rust/libzerocopy_derive.so rust/libzerocopy_derive.dylib
# clean - Delete most, but leave enough to build external modules
#
@@ -1961,6 +1962,8 @@ rustfmt:
-path $(srctree)/rust/proc-macro2 \
-o -path $(srctree)/rust/quote \
-o -path $(srctree)/rust/syn \
+ -o -path $(srctree)/rust/zerocopy \
+ -o -path $(srctree)/rust/zerocopy-derive \
\) -prune -o \
-type f -a -name '*.rs' -a ! -name '*generated*' -print \
| xargs $(RUSTFMT) $(rustfmt_flags)
@@ -2169,6 +2172,7 @@ clean: $(clean-dirs)
-o -name '*.c.[012]*.*' \
-o -name '*.ll' \
-o -name '*.gcno' \
+ -o -name '*.long-type-*.txt' \
\) -type f -print \
-o -name '.tmp_*' -print \
| xargs rm -rf

drivers/gpu/nova-core/bitfield.rs

View file
diff --git a/drivers/gpu/nova-core/bitfield.rs b/drivers/gpu/nova-core/bitfield.rs
index 02efdcf..660c391 100644
--- a/drivers/gpu/nova-core/bitfield.rs
+++ b/drivers/gpu/nova-core/bitfield.rs
@@ -170,7 +170,7 @@ macro_rules! bitfield {
(@check_field_bounds $hi:tt:$lo:tt $field:ident as bool) => {
#[allow(clippy::eq_op)]
const _: () = {
- ::kernel::build_assert!(
+ ::kernel::build_assert::build_assert!(
$hi == $lo,
concat!("boolean field `", stringify!($field), "` covers more than one bit")
);
@@ -181,7 +181,7 @@ macro_rules! bitfield {
(@check_field_bounds $hi:tt:$lo:tt $field:ident as $type:tt) => {
#[allow(clippy::eq_op)]
const _: () = {
- ::kernel::build_assert!(
+ ::kernel::build_assert::build_assert!(
$hi >= $lo,
concat!("field `", stringify!($field), "`'s MSB is smaller than its LSB")
);

drivers/gpu/nova-core/firmware.rs

View file
diff --git a/drivers/gpu/nova-core/firmware.rs b/drivers/gpu/nova-core/firmware.rs
index 6c2ab69..ad37994 100644
--- a/drivers/gpu/nova-core/firmware.rs
+++ b/drivers/gpu/nova-core/firmware.rs
@@ -48,7 +48,7 @@ fn request_firmware(
/// Structure used to describe some firmwares, notably FWSEC-FRTS.
#[repr(C)]
-#[derive(Debug, Clone)]
+#[derive(Debug, Clone, FromBytes)]
pub(crate) struct FalconUCodeDescV2 {
/// Header defined by 'NV_BIT_FALCON_UCODE_DESC_HEADER_VDESC*' in OpenRM.
hdr: u32,
@@ -84,9 +84,6 @@ pub(crate) struct FalconUCodeDescV2 {
pub(crate) alt_dmem_load_size: u32,
}
-// SAFETY: all bit patterns are valid for this type, and it doesn't use interior mutability.
-unsafe impl FromBytes for FalconUCodeDescV2 {}
-
/// Structure used to describe some firmwares, notably FWSEC-FRTS.
#[repr(C)]
#[derive(Debug, Clone)]

drivers/gpu/nova-core/gsp/cmdq.rs

View file
diff --git a/drivers/gpu/nova-core/gsp/cmdq.rs b/drivers/gpu/nova-core/gsp/cmdq.rs
index 275da9b..1c9b208 100644
--- a/drivers/gpu/nova-core/gsp/cmdq.rs
+++ b/drivers/gpu/nova-core/gsp/cmdq.rs
@@ -237,7 +237,7 @@ impl DmaGspMem {
let start = gsp_mem.dma_handle();
// Write values one by one to avoid an on-stack instance of `PteArray`.
for i in 0..GspMem::PTE_ARRAY_SIZE {
- dma_write!(gsp_mem, .ptes.0[i], PteArray::<0>::entry(start, i)?);
+ dma_write!(gsp_mem, .ptes.0[build: i], PteArray::<0>::entry(start, i)?);
}
dma_write!(
@@ -260,7 +260,7 @@ impl DmaGspMem {
let rx = self.gsp_read_ptr();
// Pointer to the first entry of the CPU message queue.
- let data = ptr::project!(mut self.0.as_mut_ptr(), .cpuq.msgq.data[0]);
+ let data = ptr::project!(mut self.0.as_mut_ptr(), .cpuq.msgq.data[build: 0]);
let (tail_end, wrap_end) = if rx == 0 {
// The write area is non-wrapping, and stops at the second-to-last entry of the command
@@ -322,7 +322,7 @@ impl DmaGspMem {
let rx = self.cpu_read_ptr();
// Pointer to the first entry of the GSP message queue.
- let data = ptr::project!(self.0.as_ptr(), .gspq.msgq.data[0]);
+ let data = ptr::project!(self.0.as_ptr(), .gspq.msgq.data[build: 0]);
let (tail_end, wrap_end) = if rx <= tx {
// Read area is non-wrapping and stops right before `tx`.

drivers/gpu/nova-core/num.rs

View file
diff --git a/drivers/gpu/nova-core/num.rs b/drivers/gpu/nova-core/num.rs
index 6c824b8..6eb174d 100644
--- a/drivers/gpu/nova-core/num.rs
+++ b/drivers/gpu/nova-core/num.rs
@@ -49,7 +49,7 @@ macro_rules! impl_safe_as {
#[allow(unused)]
#[inline(always)]
pub(crate) const fn [<$from _as_ $into>](value: $from) -> $into {
- kernel::static_assert!(size_of::<$into>() >= size_of::<$from>());
+ ::kernel::build_assert::static_assert!(size_of::<$into>() >= size_of::<$from>());
value as $into
}

drivers/gpu/nova-core/vbios.rs

View file
diff --git a/drivers/gpu/nova-core/vbios.rs b/drivers/gpu/nova-core/vbios.rs
index ebda28e..8b7d17a 100644
--- a/drivers/gpu/nova-core/vbios.rs
+++ b/drivers/gpu/nova-core/vbios.rs
@@ -16,6 +16,8 @@ use kernel::{
transmute::FromBytes,
};
+use zerocopy::FromBytes as _;
+
use crate::{
driver::Bar0,
firmware::{
@@ -1011,8 +1013,8 @@ impl FwSecBiosImage {
let data = self.base.data.get(falcon_ucode_offset..).ok_or(EINVAL)?;
match ver {
2 => {
- let v2 = FalconUCodeDescV2::from_bytes_copy_prefix(data)
- .ok_or(EINVAL)?
+ let v2 = FalconUCodeDescV2::read_from_prefix(data)
+ .map_err(|_| EINVAL)?
.0;
Ok(FalconUCodeDesc::V2(v2))
}

init/Kconfig

View file
diff --git a/init/Kconfig b/init/Kconfig
index 6da6cf0..147da63 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -2195,7 +2195,8 @@ config RUST
depends on !DEBUG_INFO_BTF || (PAHOLE_HAS_LANG_EXCLUDE && !LTO)
depends on !CFI || HAVE_CFI_ICALL_NORMALIZE_INTEGERS_RUSTC
select CFI_ICALL_NORMALIZE_INTEGERS if CFI
- depends on !KASAN_SW_TAGS
+ depends on !KASAN || CC_IS_CLANG
+ depends on !KASAN_SW_TAGS || RUSTC_VERSION >= 109600
help
Enables Rust support in the kernel.
@@ -2209,6 +2210,8 @@ config RUST
If unsure, say N.
+source "rust/kernel/Kconfig.test"
+
config RUSTC_VERSION_TEXT
string
depends on RUST

rust/Makefile

View file
diff --git a/rust/Makefile b/rust/Makefile
index b9e9f51..2fbdebb 100644
--- a/rust/Makefile
+++ b/rust/Makefile
@@ -6,6 +6,8 @@ rustdoc_output := $(objtree)/Documentation/output/rust/rustdoc
obj-$(CONFIG_RUST) += core.o compiler_builtins.o ffi.o
always-$(CONFIG_RUST) += exports_core_generated.h
+obj-$(CONFIG_RUST) += zerocopy.o
+
ifdef CONFIG_RUST_INLINE_HELPERS
always-$(CONFIG_RUST) += helpers/helpers.bc helpers/helpers_module.bc
else
@@ -47,13 +49,14 @@ endif
# Avoids running `$(RUSTC)` when it may not be available.
ifdef CONFIG_RUST
-libmacros_name := $(shell MAKEFLAGS= $(RUSTC) --print file-names --crate-name macros --crate-type proc-macro - </dev/null)
-libmacros_extension := $(patsubst libmacros.%,%,$(libmacros_name))
+procmacro-name = $(shell MAKEFLAGS= $(RUSTC) --print file-names --crate-name $(1) --crate-type proc-macro - </dev/null)
+procmacro-extension := $(patsubst libname.%,%,$(call procmacro-name,name))
-libpin_init_internal_name := $(shell MAKEFLAGS= $(RUSTC) --print file-names --crate-name pin_init_internal --crate-type proc-macro - </dev/null)
-libpin_init_internal_extension := $(patsubst libpin_init_internal.%,%,$(libpin_init_internal_name))
+libzerocopy_derive_name := $(call procmacro-name,zerocopy_derive)
+libmacros_name := $(call procmacro-name,macros)
+libpin_init_internal_name := $(call procmacro-name,pin_init_internal)
-always-$(CONFIG_RUST) += $(libmacros_name) $(libpin_init_internal_name)
+always-$(CONFIG_RUST) += $(libzerocopy_derive_name) $(libmacros_name) $(libpin_init_internal_name)
# `$(rust_flags)` is passed in case the user added `--sysroot`.
rustc_sysroot := $(shell MAKEFLAGS= $(RUSTC) $(rust_flags) --print sysroot)
@@ -81,6 +84,12 @@ core-flags := \
--edition=$(core-edition) \
$(call cfgs-to-flags,$(core-cfgs))
+zerocopy-flags := \
+ --cap-lints=allow
+
+zerocopy-envs := \
+ CARGO_PKG_VERSION=0.8.50
+
proc_macro2-cfgs := \
feature="proc-macro" \
wrap_proc_macro \
@@ -118,6 +127,12 @@ syn-flags := \
--extern quote \
$(call cfgs-to-flags,$(syn-cfgs))
+zerocopy_derive-flags := \
+ --cap-lints=allow \
+ --extern proc_macro2 \
+ --extern quote \
+ --extern syn
+
pin_init_internal-cfgs := \
kernel USE_RUSTC_FEATURES
@@ -144,6 +159,7 @@ doctests_modifiers_workaround := $(rustdoc_modifiers_workaround)$(if $(call rust
quiet_cmd_rustdoc = RUSTDOC $(if $(rustdoc_host),H, ) $<
cmd_rustdoc = \
+ $(rustc_target_envs) \
OBJTREE=$(abspath $(objtree)) \
$(RUSTDOC) $(filter-out $(skip_flags) --remap-path-scope=%,$(if $(rustdoc_host),$(rust_common_flags),$(rust_flags))) \
$(rustc_target_flags) -L$(objtree)/$(obj) \
@@ -166,7 +182,7 @@ quiet_cmd_rustdoc = RUSTDOC $(if $(rustdoc_host),H, ) $<
# command-like flags to solve the issue. Meanwhile, we use the non-custom case
# and then retouch the generated files.
rustdoc: rustdoc-core rustdoc-macros rustdoc-compiler_builtins \
- rustdoc-kernel rustdoc-pin_init
+ rustdoc-kernel rustdoc-pin_init rustdoc-zerocopy rustdoc-zerocopy_derive
$(Q)grep -Ehro '<a href="srctree/([^"]+)"' $(rustdoc_output) | \
cut -d'"' -f2 | cut -d/ -f2- | while read f; do \
if [ ! -e "$(srctree)/$$f" ]; then \
@@ -199,6 +215,12 @@ rustdoc-syn: private rustc_target_flags = $(syn-flags)
rustdoc-syn: $(src)/syn/lib.rs rustdoc-clean rustdoc-quote FORCE
+$(call if_changed,rustdoc)
+rustdoc-zerocopy_derive: private rustdoc_host = yes
+rustdoc-zerocopy_derive: private rustc_target_flags = $(zerocopy_derive-flags) \
+ --extern proc_macro --crate-type proc-macro
+rustdoc-zerocopy_derive: $(src)/zerocopy-derive/lib.rs rustdoc-clean rustdoc-syn FORCE
+ +$(call if_changed,rustdoc)
+
rustdoc-macros: private rustdoc_host = yes
rustdoc-macros: private rustc_target_flags = --crate-type proc-macro \
--extern proc_macro --extern proc_macro2 --extern quote --extern syn
@@ -218,6 +240,13 @@ rustdoc-compiler_builtins: private is-kernel-object := y
rustdoc-compiler_builtins: $(src)/compiler_builtins.rs rustdoc-core FORCE
+$(call if_changed,rustdoc)
+rustdoc-zerocopy: private rustc_target_envs := $(zerocopy-envs)
+rustdoc-zerocopy: private is-kernel-object := y
+rustdoc-zerocopy: private rustc_target_flags = $(zerocopy-flags) \
+ --extend-css $(src)/zerocopy/rustdoc/style.css
+rustdoc-zerocopy: $(src)/zerocopy/src/lib.rs rustdoc-clean rustdoc-core FORCE
+ +$(call if_changed,rustdoc)
+
rustdoc-ffi: private is-kernel-object := y
rustdoc-ffi: $(src)/ffi.rs rustdoc-core FORCE
+$(call if_changed,rustdoc)
@@ -239,7 +268,8 @@ rustdoc-pin_init: $(src)/pin-init/src/lib.rs rustdoc-pin_init_internal \
rustdoc-kernel: private is-kernel-object := y
rustdoc-kernel: private rustc_target_flags = --extern ffi --extern pin_init \
--extern build_error --extern macros \
- --extern bindings --extern uapi
+ --extern bindings --extern uapi \
+ --extern zerocopy --extern zerocopy_derive
rustdoc-kernel: $(src)/kernel/lib.rs rustdoc-core rustdoc-ffi rustdoc-macros \
rustdoc-pin_init rustdoc-compiler_builtins $(obj)/$(libmacros_name) \
$(obj)/bindings.o FORCE
@@ -250,6 +280,7 @@ rustdoc-clean: FORCE
quiet_cmd_rustc_test_library = $(RUSTC_OR_CLIPPY_QUIET) TL $<
cmd_rustc_test_library = \
+ $(rustc_target_envs) \
OBJTREE=$(abspath $(objtree)) \
$(RUSTC_OR_CLIPPY) $(filter-out $(skip_flags),$(rust_common_flags) $(rustc_target_flags)) \
@$(objtree)/include/generated/rustc_cfg \
@@ -258,6 +289,11 @@ quiet_cmd_rustc_test_library = $(RUSTC_OR_CLIPPY_QUIET) TL $<
-L$(objtree)/$(obj)/test \
--crate-name $(subst rusttest-,,$(subst rusttestlib-,,$@)) $<
+rusttestlib-zerocopy: private rustc_target_envs := $(zerocopy-envs)
+rusttestlib-zerocopy: private rustc_target_flags = $(zerocopy-flags)
+rusttestlib-zerocopy: $(src)/zerocopy/src/lib.rs FORCE
+ +$(call if_changed,rustc_test_library)
+
rusttestlib-build_error: $(src)/build_error.rs FORCE
+$(call if_changed,rustc_test_library)
@@ -277,6 +313,12 @@ rusttestlib-syn: private rustc_target_flags = $(syn-flags)
rusttestlib-syn: $(src)/syn/lib.rs rusttestlib-quote FORCE
+$(call if_changed,rustc_test_library)
+rusttestlib-zerocopy_derive: private rustc_target_flags = $(zerocopy_derive-flags) \
+ --extern proc_macro
+rusttestlib-zerocopy_derive: private rustc_test_library_proc = yes
+rusttestlib-zerocopy_derive: $(src)/zerocopy-derive/lib.rs rusttestlib-syn FORCE
+ +$(call if_changed,rustc_test_library)
+
rusttestlib-macros: private rustc_target_flags = --extern proc_macro \
--extern proc_macro2 --extern quote --extern syn
rusttestlib-macros: private rustc_test_library_proc = yes
@@ -298,10 +340,11 @@ rusttestlib-pin_init: $(src)/pin-init/src/lib.rs rusttestlib-macros \
rusttestlib-kernel: private rustc_target_flags = --extern ffi \
--extern build_error --extern macros --extern pin_init \
- --extern bindings --extern uapi
+ --extern bindings --extern uapi \
+ --extern zerocopy --extern zerocopy_derive
rusttestlib-kernel: $(src)/kernel/lib.rs rusttestlib-bindings rusttestlib-uapi \
rusttestlib-build_error rusttestlib-pin_init $(obj)/$(libmacros_name) \
- $(obj)/bindings.o FORCE
+ $(obj)/bindings.o rusttestlib-zerocopy rusttestlib-zerocopy_derive FORCE
+$(call if_changed,rustc_test_library)
rusttestlib-bindings: private rustc_target_flags = --extern ffi --extern pin_init
@@ -314,6 +357,7 @@ rusttestlib-uapi: $(src)/uapi/lib.rs rusttestlib-ffi rusttestlib-pin_init FORCE
quiet_cmd_rustdoc_test = RUSTDOC T $<
cmd_rustdoc_test = \
+ $(rustc_target_envs) \
RUST_MODFILE=test.rs \
OBJTREE=$(abspath $(objtree)) \
$(RUSTDOC) --test $(rust_common_flags) \
@@ -328,11 +372,13 @@ quiet_cmd_rustdoc_test_kernel = RUSTDOC TK $<
cmd_rustdoc_test_kernel = \
rm -rf $(objtree)/$(obj)/test/doctests/kernel; \
mkdir -p $(objtree)/$(obj)/test/doctests/kernel; \
+ $(rustc_target_envs) \
OBJTREE=$(abspath $(objtree)) \
$(RUSTDOC) --test $(filter-out --remap-path-scope=%,$(rust_flags)) \
-L$(objtree)/$(obj) --extern ffi --extern pin_init \
--extern kernel --extern build_error --extern macros \
--extern bindings --extern uapi \
+ --extern zerocopy --extern zerocopy_derive \
--no-run --crate-name kernel -Zunstable-options \
--sysroot=/dev/null \
$(doctests_modifiers_workaround) \
@@ -350,6 +396,7 @@ quiet_cmd_rustdoc_test_kernel = RUSTDOC TK $<
# so for the moment we skip `-Cpanic=abort`.
quiet_cmd_rustc_test = $(RUSTC_OR_CLIPPY_QUIET) T $<
cmd_rustc_test = \
+ $(rustc_target_envs) \
OBJTREE=$(abspath $(objtree)) \
$(RUSTC_OR_CLIPPY) --test $(rust_common_flags) \
@$(objtree)/include/generated/rustc_cfg \
@@ -517,8 +564,9 @@ $(obj)/exports_bindings_generated.h: $(obj)/bindings.o FORCE
$(obj)/exports_kernel_generated.h: $(obj)/kernel.o FORCE
$(call if_changed,exports)
-quiet_cmd_rustc_procmacrolibrary = $(RUSTC_OR_CLIPPY_QUIET) PL $@
+quiet_cmd_rustc_procmacrolibrary = $(if $(skip_clippy),RUSTC,$(RUSTC_OR_CLIPPY_QUIET)) PL $@
cmd_rustc_procmacrolibrary = \
+ $(rustc_target_envs) \
$(if $(skip_clippy),$(RUSTC),$(RUSTC_OR_CLIPPY)) \
$(filter-out $(skip_flags),$(rust_common_flags) $(rustc_target_flags)) \
--emit=dep-info=$(depfile) --emit=link=$@ --crate-type rlib -O \
@@ -541,17 +589,24 @@ $(obj)/libsyn.rlib: private rustc_target_flags = $(syn-flags)
$(obj)/libsyn.rlib: $(src)/syn/lib.rs $(obj)/libquote.rlib FORCE
+$(call if_changed_dep,rustc_procmacrolibrary)
-quiet_cmd_rustc_procmacro = $(RUSTC_OR_CLIPPY_QUIET) P $@
+quiet_cmd_rustc_procmacro = $(if $(skip_clippy),RUSTC,$(RUSTC_OR_CLIPPY_QUIET)) P $@
cmd_rustc_procmacro = \
- $(RUSTC_OR_CLIPPY) $(rust_common_flags) $(rustc_target_flags) \
+ $(rustc_target_envs) \
+ $(if $(skip_clippy),$(RUSTC),$(RUSTC_OR_CLIPPY)) $(rust_common_flags) $(rustc_target_flags) \
-Clinker-flavor=gcc -Clinker=$(HOSTCC) \
-Clink-args='$(call escsq,$(KBUILD_PROCMACROLDFLAGS))' \
--emit=dep-info=$(depfile) --emit=link=$@ --extern proc_macro \
--crate-type proc-macro -L$(objtree)/$(obj) \
- --crate-name $(patsubst lib%.$(libmacros_extension),%,$(notdir $@)) \
+ --crate-name $(patsubst lib%.$(procmacro-extension),%,$(notdir $@)) \
@$(objtree)/include/generated/rustc_cfg $<
# Procedural macros can only be used with the `rustc` that compiled it.
+$(obj)/$(libzerocopy_derive_name): private skip_clippy = 1
+$(obj)/$(libzerocopy_derive_name): private rustc_target_flags = $(zerocopy_derive-flags)
+$(obj)/$(libzerocopy_derive_name): $(src)/zerocopy-derive/lib.rs $(obj)/libproc_macro2.rlib \
+ $(obj)/libquote.rlib $(obj)/libsyn.rlib FORCE
+ +$(call if_changed_dep,rustc_procmacro)
+
$(obj)/$(libmacros_name): private rustc_target_flags = \
--extern proc_macro2 --extern quote --extern syn
$(obj)/$(libmacros_name): $(src)/macros/lib.rs $(obj)/libproc_macro2.rlib \
@@ -567,6 +622,7 @@ $(obj)/$(libpin_init_internal_name): $(src)/pin-init/internal/src/lib.rs \
# since Rust 1.95.0 (https://github.com/rust-lang/rust/pull/151534).
quiet_cmd_rustc_library = $(if $(skip_clippy),RUSTC,$(RUSTC_OR_CLIPPY_QUIET)) L $@
cmd_rustc_library = \
+ $(rustc_target_envs) \
OBJTREE=$(abspath $(objtree)) \
$(if $(skip_clippy),$(RUSTC),$(RUSTC_OR_CLIPPY)) \
$(filter-out $(skip_flags),$(rust_flags)) $(rustc_target_flags) \
@@ -591,6 +647,7 @@ rust-analyzer:
--cfgs='syn=$(syn-cfgs)' \
--cfgs='pin_init_internal=$(pin_init_internal-cfgs)' \
--cfgs='pin_init=$(pin_init-cfgs)' \
+ --envs='zerocopy=$(zerocopy-envs)' \
$(realpath $(srctree)) $(realpath $(objtree)) \
$(rustc_sysroot) $(RUST_LIB_SRC) $(if $(KBUILD_EXTMOD),$(srcroot)) \
> rust-project.json
@@ -662,6 +719,13 @@ $(obj)/compiler_builtins.o: private rustc_objcopy = -w -W '__*'
$(obj)/compiler_builtins.o: $(src)/compiler_builtins.rs $(obj)/core.o FORCE
+$(call if_changed_rule,rustc_library)
+$(obj)/zerocopy.o: private skip_clippy = 1
+$(obj)/zerocopy.o: private skip_gendwarfksyms = 1
+$(obj)/zerocopy.o: private rustc_target_envs := $(zerocopy-envs)
+$(obj)/zerocopy.o: private rustc_target_flags = $(zerocopy-flags)
+$(obj)/zerocopy.o: $(src)/zerocopy/src/lib.rs $(obj)/compiler_builtins.o FORCE
+ +$(call if_changed_rule,rustc_library)
+
$(obj)/pin_init.o: private skip_gendwarfksyms = 1
$(obj)/pin_init.o: private rustc_target_flags = $(pin_init-flags)
$(obj)/pin_init.o: $(src)/pin-init/src/lib.rs $(obj)/compiler_builtins.o \
@@ -697,9 +761,11 @@ $(obj)/uapi.o: $(src)/uapi/lib.rs \
+$(call if_changed_rule,rustc_library)
$(obj)/kernel.o: private rustc_target_flags = --extern ffi --extern pin_init \
- --extern build_error --extern macros --extern bindings --extern uapi
+ --extern build_error --extern macros --extern bindings --extern uapi \
+ --extern zerocopy --extern zerocopy_derive
$(obj)/kernel.o: $(src)/kernel/lib.rs $(obj)/build_error.o $(obj)/pin_init.o \
- $(obj)/$(libmacros_name) $(obj)/bindings.o $(obj)/uapi.o FORCE
+ $(obj)/$(libmacros_name) $(obj)/bindings.o $(obj)/uapi.o \
+ $(obj)/zerocopy.o $(obj)/$(libzerocopy_derive_name) FORCE
+$(call if_changed_rule,rustc_library)
ifdef CONFIG_JUMP_LABEL

rust/kernel/Kconfig.test

View file
diff --git a/rust/kernel/Kconfig.test b/rust/kernel/Kconfig.test
new file mode 100644
index 0000000..e6a5c7a
--- /dev/null
+++ b/rust/kernel/Kconfig.test
@@ -0,0 +1,86 @@
+# SPDX-License-Identifier: GPL-2.0-only
+menuconfig RUST_KUNIT_TESTS
+ bool "Rust KUnit tests"
+ depends on KUNIT && RUST
+ default KUNIT_ALL_TESTS
+ help
+ This menu collects all options for Rust KUnit tests.
+ See Documentation/rust/testing.rst for how to protect
+ unit tests with these options.
+
+ Say Y here to enable Rust KUnit tests.
+
+ If unsure, say N.
+
+if RUST_KUNIT_TESTS
+config RUST_ALLOCATOR_KUNIT_TEST
+ bool "KUnit tests for Rust allocator API" if !KUNIT_ALL_TESTS
+ default KUNIT_ALL_TESTS
+ help
+ This option enables KUnit tests for the Rust allocator API.
+ These are only for development and testing, not for regular
+ kernel use cases.
+
+ If unsure, say N.
+
+config RUST_KVEC_KUNIT_TEST
+ bool "KUnit tests for Rust KVec API" if !KUNIT_ALL_TESTS
+ default KUNIT_ALL_TESTS
+ help
+ This option enables KUnit tests for the Rust KVec API.
+ These are only for development and testing, not for
+ regular kernel use cases.
+
+ If unsure, say N.
+
+config RUST_BITMAP_KUNIT_TEST
+ bool "KUnit tests for Rust bitmap API" if !KUNIT_ALL_TESTS
+ default KUNIT_ALL_TESTS
+ help
+ This option enables KUnit tests for the Rust bitmap API.
+ These are only for development and testing, not for regular
+ kernel use cases.
+
+ If unsure, say N.
+
+config RUST_KUNIT_SELFTEST
+ bool "KUnit selftests for Rust" if !KUNIT_ALL_TESTS
+ default KUNIT_ALL_TESTS
+ help
+ This option enables KUnit selftests. These are only
+ for development and testing, not for regular kernel
+ use cases.
+
+ If unsure, say N.
+
+config RUST_STR_KUNIT_TEST
+ bool "KUnit tests for Rust strings API" if !KUNIT_ALL_TESTS
+ default KUNIT_ALL_TESTS
+ help
+ This option enables KUnit tests for the Rust strings API.
+ These are only for development and testing, not for regular
+ kernel use cases.
+
+ If unsure, say N.
+
+config RUST_ATOMICS_KUNIT_TEST
+ bool "KUnit tests for Rust atomics API" if !KUNIT_ALL_TESTS
+ default KUNIT_ALL_TESTS
+ help
+ This option enables KUnit tests for the Rust atomics API.
+ These are only for development and testing, not for regular
+ kernel use cases.
+
+ If unsure, say N.
+
+config RUST_BITFIELD_KUNIT_TEST
+ bool "KUnit tests for the Rust `bitfield!` macro" if !KUNIT_ALL_TESTS
+ default KUNIT_ALL_TESTS
+ help
+ This option enables KUnit tests for the Rust `bitfield!` macro.
+ These are only for development and testing, not for regular
+ kernel use cases.
+
+ If unsure, say N.

This diff is incomplete. Download the complete patch.

rust/kernel/alloc.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/alloc/allocator.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/alloc/allocator/iter.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/alloc/kbox.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/alloc/kvec.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/alloc/kvec/errors.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/alloc/layout.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/bitfield.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/bitmap.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/build_assert.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/cpufreq.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/dma.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/error.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/fmt.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/init.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/io/register.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/io/resource.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/ioctl.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/kunit.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/lib.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/net/phy/reg.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/num/bounded.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/page.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/prelude.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/ptr/projection.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/str.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/sync/arc.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/sync/aref.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/sync/atomic/internal.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/sync/atomic/predefine.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/sync/lock/global.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/sync/locked_by.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/sync/refcount.rs

View file

This diff is incomplete. Download the complete patch.

rust/kernel/xarray.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/README.md

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/examples/big_struct_in_place.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/examples/error.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/examples/linked_list.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/examples/mutex.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/examples/pthread_mutex.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/examples/static_init.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/internal/src/diagnostics.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/internal/src/init.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/internal/src/lib.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/internal/src/pin_data.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/internal/src/zeroable.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/src/__internal.rs

View file

This diff is incomplete. Download the complete patch.

rust/pin-init/src/lib.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/README.md

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/derive/from_bytes.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/derive/into_bytes.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/derive/known_layout.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/derive/mod.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/derive/try_from_bytes.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/derive/unaligned.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/lib.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/repr.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy-derive/util.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/README.md

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/as_bytes_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/as_bytes_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/as_bytes_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/as_bytes_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/as_bytes_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/as_bytes_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/extend_vec_zeroed.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/extend_vec_zeroed.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/extend_vec_zeroed.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/formats/coco_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/formats/coco_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/formats/coco_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/insert_vec_zeroed.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/insert_vec_zeroed.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/insert_vec_zeroed.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_box_zeroed.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_box_zeroed.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_box_zeroed.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_box_zeroed_with_elems_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_vec_zeroed.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_vec_zeroed.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_vec_zeroed.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_zeroed.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_zeroed.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/new_zeroed.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/read_from_bytes.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/read_from_bytes.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/read_from_bytes.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/read_from_prefix.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/read_from_prefix.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/read_from_prefix.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/read_from_suffix.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/read_from_suffix.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/read_from_suffix.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_bytes_with_elems_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_prefix_with_elems_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/ref_from_suffix_with_elems_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_unchecked_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_unchecked_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_unchecked_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_unchecked_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_unchecked_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_at_unchecked_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_immutable_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_immutable_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_immutable_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_immutable_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_immutable_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_immutable_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_runtime_check_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_runtime_check_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_runtime_check_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_runtime_check_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_runtime_check_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_runtime_check_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_unchecked_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_unchecked_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_unchecked_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_unchecked_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_unchecked_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/split_via_unchecked_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/transmute.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/transmute.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/transmute.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/transmute_ref_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/transmute_ref_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/transmute_ref_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/transmute_ref_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/transmute_ref_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/transmute_ref_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_read_from_bytes.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_read_from_bytes.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_read_from_bytes.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_read_from_prefix.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_read_from_prefix.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_read_from_prefix.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_read_from_suffix.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_read_from_suffix.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_read_from_suffix.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_bytes_with_elems_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_prefix_with_elems_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_ref_from_suffix_with_elems_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_transmute.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_transmute.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_transmute.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_transmute_ref_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_transmute_ref_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_transmute_ref_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_transmute_ref_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_transmute_ref_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/try_transmute_ref_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_prefix_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_prefix_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_prefix_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_prefix_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_prefix_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_prefix_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_suffix_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_suffix_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_suffix_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_suffix_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_suffix_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/write_to_suffix_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/zero_dynamic_padding.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/zero_dynamic_padding.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/zero_dynamic_padding.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/zero_dynamic_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/zero_dynamic_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/zero_dynamic_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/zero_static_size.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/zero_static_size.x86-64

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/benches/zero_static_size.x86-64.mca

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/rustdoc/style.css

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/byte_slice.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/byteorder.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/deprecated.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/error.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/impls.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/layout.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/lib.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/macros.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/pointer/inner.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/pointer/invariant.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/pointer/mod.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/pointer/ptr.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/pointer/transmute.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/ref.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/split_at.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/util/macro_util.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/util/macros.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/util/mod.rs

View file

This diff is incomplete. Download the complete patch.

rust/zerocopy/src/wrappers.rs

View file

This diff is incomplete. Download the complete patch.

samples/rust/rust_dma.rs

View file

This diff is incomplete. Download the complete patch.

scripts/Makefile.autofdo

View file

This diff is incomplete. Download the complete patch.

scripts/Makefile.build

View file

This diff is incomplete. Download the complete patch.

scripts/Makefile.kasan

View file

This diff is incomplete. Download the complete patch.

scripts/Makefile.lib

View file

This diff is incomplete. Download the complete patch.

scripts/generate_rust_analyzer.py

View file

This diff is incomplete. Download the complete patch.