eal: remove use of register keyword
The 'register' keyword does nothing, and has been removed in C++17. Remove it for compatibility. Signed-off-by: Avi Kivity <avi@scylladb.com>
This commit is contained in:
parent
7eafccfa9d
commit
0d5f2ed12f
@ -50,7 +50,7 @@ extern "C" {
|
||||
|
||||
static inline uint16_t rte_arch_bswap16(uint16_t _x)
|
||||
{
|
||||
register uint16_t x = _x;
|
||||
uint16_t x = _x;
|
||||
|
||||
asm volatile ("rev16 %w0,%w1"
|
||||
: "=r" (x)
|
||||
|
@ -24,7 +24,7 @@ extern "C" {
|
||||
*/
|
||||
static inline uint16_t rte_arch_bswap16(uint16_t _x)
|
||||
{
|
||||
register uint16_t x = _x;
|
||||
uint16_t x = _x;
|
||||
asm volatile ("xchgb %b[x1],%h[x2]"
|
||||
: [x1] "=Q" (x)
|
||||
: [x2] "0" (x)
|
||||
@ -39,7 +39,7 @@ static inline uint16_t rte_arch_bswap16(uint16_t _x)
|
||||
*/
|
||||
static inline uint32_t rte_arch_bswap32(uint32_t _x)
|
||||
{
|
||||
register uint32_t x = _x;
|
||||
uint32_t x = _x;
|
||||
asm volatile ("bswap %[x]"
|
||||
: [x] "+r" (x)
|
||||
);
|
||||
|
Loading…
x
Reference in New Issue
Block a user