xref: /dpdk/app/test/test_prefetch.c (revision 14ad4f01845331a0ae98c681efa3086eeed3343a)
1 /* SPDX-License-Identifier: BSD-3-Clause
2  * Copyright(c) 2010-2014 Intel Corporation
3  */
4 
5 #include <stdio.h>
6 #include <stdint.h>
7 
8 #include <rte_prefetch.h>
9 
10 #include "test.h"
11 
12 /*
13  * Prefetch test
14  * =============
15  *
16  * - Just test that the macro can be called and validate the compilation.
17  *   The test always return success.
18  */
19 
20 static int
21 test_prefetch(void)
22 {
23 	int a;
24 
25 	rte_prefetch0(&a);
26 	rte_prefetch1(&a);
27 	rte_prefetch2(&a);
28 
29 	return 0;
30 }
31 
32 REGISTER_TEST_COMMAND(prefetch_autotest, test_prefetch);
33