memset-archs.S (e5451c8f8330e03ad3cfa16048b4daf961af434f) | memset-archs.S (86effd0dc675c36caed7b954d7f4f63b77c353b5) |
---|---|
1/* 2 * Copyright (C) 2014-15 Synopsys, Inc. (www.synopsys.com) 3 * 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License version 2 as 6 * published by the Free Software Foundation. 7 */ 8 9#include <linux/linkage.h> 10 11#undef PREALLOC_NOT_AVAIL 12 | 1/* 2 * Copyright (C) 2014-15 Synopsys, Inc. (www.synopsys.com) 3 * 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License version 2 as 6 * published by the Free Software Foundation. 7 */ 8 9#include <linux/linkage.h> 10 11#undef PREALLOC_NOT_AVAIL 12 |
13ENTRY(memset) | 13ENTRY_CFI(memset) |
14 prefetchw [r0] ; Prefetch the write location 15 mov.f 0, r2 16;;; if size is zero 17 jz.d [blink] 18 mov r3, r0 ; don't clobber ret val 19 20;;; if length < 8 21 brls.d.nt r2, 8, .Lsmallchunk --- 85 unchanged lines hidden (view full) --- 107.Lsmallchunk: 108 lpnz .Lcopy3bytes 109 ;; LOOP START 110 stb.ab r1, [r3, 1] 111.Lcopy3bytes: 112 113 j [blink] 114 | 14 prefetchw [r0] ; Prefetch the write location 15 mov.f 0, r2 16;;; if size is zero 17 jz.d [blink] 18 mov r3, r0 ; don't clobber ret val 19 20;;; if length < 8 21 brls.d.nt r2, 8, .Lsmallchunk --- 85 unchanged lines hidden (view full) --- 107.Lsmallchunk: 108 lpnz .Lcopy3bytes 109 ;; LOOP START 110 stb.ab r1, [r3, 1] 111.Lcopy3bytes: 112 113 j [blink] 114 |
115END(memset) | 115END_CFI(memset) |
116 | 116 |
117ENTRY(memzero) | 117ENTRY_CFI(memzero) |
118 ; adjust bzero args to memset args 119 mov r2, r1 120 b.d memset ;tail call so need to tinker with blink 121 mov r1, 0 | 118 ; adjust bzero args to memset args 119 mov r2, r1 120 b.d memset ;tail call so need to tinker with blink 121 mov r1, 0 |
122END(memzero) | 122END_CFI(memzero) |