diff options
author | Arthur Cohen <arthur.cohen@embecosm.com> | 2022-08-10 16:08:38 +0200 |
---|---|---|
committer | Arthur Cohen <arthur.cohen@embecosm.com> | 2022-08-16 11:29:00 +0200 |
commit | f68ecc7e5914ef99b22c258e404c73b2401f9d89 (patch) | |
tree | f790a4bc549fcaee5e73a566f1507a5eae7b525b /gcc/rust/backend/rust-compile-resolve-path.cc | |
parent | 021e4953390da748515debfc8973149457d3118a (diff) | |
download | gcc-f68ecc7e5914ef99b22c258e404c73b2401f9d89.zip gcc-f68ecc7e5914ef99b22c258e404c73b2401f9d89.tar.gz gcc-f68ecc7e5914ef99b22c258e404c73b2401f9d89.tar.bz2 |
intrinsics: Add copy_nonoverlapping<T>
This intrinsic is similar to C's memcpy (or in our case, GCC's
__builtin_memcpy) with the order of arguments swapped and knowledge
about the type of the operands. So we can desugar the following calls:
`copy_nonoverlapping::<T>(src, dst, count)`
can be converted to
`__builtin_memcpy(dst, src, count * size_of::<T>())`
Finally, unlike most intrinsics, copy_nonoverlapping must be marked as impure
Co-authored-by: philbert <philip.herron@embecosm.com>
Diffstat (limited to 'gcc/rust/backend/rust-compile-resolve-path.cc')
0 files changed, 0 insertions, 0 deletions