diff options
Diffstat (limited to 'test/monniaux/memcpy')
-rw-r--r-- | test/monniaux/memcpy/test_memcpy.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/test/monniaux/memcpy/test_memcpy.c b/test/monniaux/memcpy/test_memcpy.c new file mode 100644 index 00000000..4a055692 --- /dev/null +++ b/test/monniaux/memcpy/test_memcpy.c @@ -0,0 +1,15 @@ +#include <stdio.h> + +int main() { + char buf1[16], buf2[16]; + for(int i=0; i<16; i++) { + buf1[i] = i; + } + for(int i=0; i<16; i++) { + buf2[i] = 100+i; + } + __builtin_memcpy_aligned(buf1, buf2+3, 4, 1); + for(int i=0; i<16; i++) { + printf("%d : %d\n", i, buf1[i]); + } +} |