mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-01-26 11:25:27 +00:00
[libc] Add rep;movsb as an accelerator under x86
This commit is contained in:
parent
f256c39541
commit
ad82fe7b28
@ -163,6 +163,12 @@ using _64 = __llvm_libc::Repeated<_8, 8>;
|
||||
using _128 = __llvm_libc::Repeated<_8, 16>;
|
||||
#endif
|
||||
|
||||
struct Accelerator {
|
||||
static void Copy(char *dst, const char *src, size_t count) {
|
||||
asm volatile("rep movsb" : "+D"(dst), "+S"(src), "+c"(count) : : "memory");
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace x86
|
||||
} // namespace __llvm_libc
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user