arch/sparc/lib/memcmp.S
Source file repositories/reference/linux-study-clean/arch/sparc/lib/memcmp.S
File Facts
- System
- Linux kernel
- Corpus path
arch/sparc/lib/memcmp.S- Extension
.S- Size
- 565 bytes
- Lines
- 31
- Domain
- Architecture Layer
- Bucket
- arch/sparc
- Inferred role
- Architecture Layer: exported/initcall integration point
- Status
- integration implementation candidate
Why This File Exists
CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
Dependency Surface
linux/export.hlinux/linkage.hasm/asm.h
Detected Declarations
export memcmp
Annotated Snippet
#include <linux/export.h>
#include <linux/linkage.h>
#include <asm/asm.h>
.text
ENTRY(memcmp)
cmp %o2, 0
1: BRANCH32(be, pn, 2f)
nop
ldub [%o0], %g7
ldub [%o1], %g3
sub %o2, 1, %o2
add %o0, 1, %o0
add %o1, 1, %o1
subcc %g7, %g3, %g3
BRANCH32(be, pt, 1b)
cmp %o2, 0
retl
mov %g3, %o0
2: retl
mov 0, %o0
ENDPROC(memcmp)
EXPORT_SYMBOL(memcmp)
Annotation
- Immediate include surface: `linux/export.h`, `linux/linkage.h`, `asm/asm.h`.
- Detected declarations: `export memcmp`.
- Atlas domain: Architecture Layer / arch/sparc.
- Implementation status: integration implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.