/*1* Copyright (C) 2007 Marc Hoffman2*3* This file is part of FFmpeg.4*5* FFmpeg is free software; you can redistribute it and/or6* modify it under the terms of the GNU Lesser General Public7* License as published by the Free Software Foundation; either8* version 2.1 of the License, or (at your option) any later version.9*10* FFmpeg is distributed in the hope that it will be useful,11* but WITHOUT ANY WARRANTY; without even the implied warranty of12* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU13* Lesser General Public License for more details.14*15* You should have received a copy of the GNU Lesser General Public16* License along with FFmpeg; if not, write to the Free Software17* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA18*/1920/**21* @file22* byte swapping routines23*/2425#ifndef AVUTIL_BFIN_BSWAP_H26#define AVUTIL_BFIN_BSWAP_H2728#include <stdint.h>29#include "config.h"30#include "libavutil/attributes.h"3132#define av_bswap32 av_bswap3233static av_always_inline av_const uint32_t av_bswap32(uint32_t x)34{35unsigned tmp;36__asm__("%1 = %0 >> 8 (V); \n\t"37"%0 = %0 << 8 (V); \n\t"38"%0 = %0 | %1; \n\t"39"%0 = PACK(%0.L, %0.H); \n\t"40: "+d"(x), "=&d"(tmp));41return x;42}4344#endif /* AVUTIL_BFIN_BSWAP_H */454647