mailing list of musl libc
 help / color / mirror / code / Atom feed
blob 1131c52b8b72d634a960e8442ba4b754681587af 716 bytes (raw)
name: src/string/riscv64/memcpy_vector.S 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
 
    .text
    .global __memcpy_vect
    .type __memcpy_vect,%function
    .option push
    .option arch, +v
/* void *__memcpy_vect(void *dest, const void *src, size_t n)
 * a0 = dest, a1 = src, a2 = n
 * Returns a0.
 */
__memcpy_vect:
    mv      t0, a0                    /* running dst */
    mv      t1, a1                    /* running src */
    beqz    a2, .Ldone_copy           /* n == 0 then return */

.Lbulk_copy:
    vsetvli t2, a2, e8, m8, ta, ma    /* t2 = vl (bytes) */
    vle8.v  v0, (t1)
    vse8.v  v0, (t0)
    add     t0, t0, t2
    add     t1, t1, t2
    sub     a2, a2, t2
    bnez    a2, .Lbulk_copy
    /* fallthrough */

.Ldone_copy:
    ret
.size __memcpy_vect, .-__memcpy_vect
.option pop

debug log:

solving 1131c52b ...
found 1131c52b in https://inbox.vuxu.org/musl/20251119054059.514848-2-pincheng.plct@isrc.iscas.ac.cn/

applying [1/1] https://inbox.vuxu.org/musl/20251119054059.514848-2-pincheng.plct@isrc.iscas.ac.cn/
diff --git a/src/string/riscv64/memcpy_vector.S b/src/string/riscv64/memcpy_vector.S
new file mode 100644
index 00000000..1131c52b

Checking patch src/string/riscv64/memcpy_vector.S...
Applied patch src/string/riscv64/memcpy_vector.S cleanly.

index at:
100644 1131c52b8b72d634a960e8442ba4b754681587af	src/string/riscv64/memcpy_vector.S

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).