From patchwork Fri Sep 16 02:08:47 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Almer X-Patchwork-Id: 600 Delivered-To: ffmpegpatchwork@gmail.com Received: by 10.103.140.134 with SMTP id o128csp214567vsd; Thu, 15 Sep 2016 19:09:43 -0700 (PDT) X-Received: by 10.28.67.132 with SMTP id q126mr785267wma.84.1473991783714; Thu, 15 Sep 2016 19:09:43 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id a4si2259843wme.75.2016.09.15.19.09.38; Thu, 15 Sep 2016 19:09:43 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE dis=NONE) header.from=gmail.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 65F4F689EE4; Fri, 16 Sep 2016 05:09:23 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-oi0-f67.google.com (mail-oi0-f67.google.com [209.85.218.67]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 69DE3689E5A for ; Fri, 16 Sep 2016 05:09:17 +0300 (EEST) Received: by mail-oi0-f67.google.com with SMTP id w11so5542639oia.0 for ; Thu, 15 Sep 2016 19:09:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id; bh=T/JtQO9kPrnfk0GGPZOPctjdaJ8+yKjqevPsdX3rL9c=; b=zRgPhjC+QEQYOTLqJhddyJDfku1ttXo5iF0nWIhIYDRKyhxENTQBnFKn+A9qwK0Dlc QvsnJ72WcLGSG6rbZCBuaRMdpQxVmIGNuwtjD7HZ5nWRRPmZu1wd7HNK3d3kdn0/BEvb FsHguqZU1+Smo/NZCJr6yIob7LzDWV/vj7AnsLE384w2VHA30RCz3PJIP4/SpkkUZrBK +5Z0XhZUg96yX564kkXBf/GFyQgwDc56uEO/UEPKGn48Q5eCqkzbMJGp+Rm8wXfCfP65 SKbSxzdTbrl75/sxIasbPu90ORXdw0dff0GdrHQQjQECzu0zkHKNyz+cz95chvQV4Yti 1hSw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:subject:date:message-id; bh=T/JtQO9kPrnfk0GGPZOPctjdaJ8+yKjqevPsdX3rL9c=; b=NpSHxezkIIw9Wr3/A00R5AwGmIuZuyXQs8q99TErYf9p0aKac/izaRv7KsIUq3ihIe Fr/It9Zbl37XWIinc38llJesAmJh/5/IHXC8Hqez0OKJGVZ3v5XSMH9KcoClKjgFhwez CkMqDZtneQAmR7eRmkKoeHccAZ4fXh27CbOaYfPh1xwm9WRN1PC2jSY/RvAnbNR2SI5U rRrb6L2PrsBC5Q7r6KLj8A8lWYO4iwsOVetzDyrwWimzaVfuGlBeYcUfECaLXLUG7zsb 1Mf03ePMG6zeQqVCwmq4YDZZptQfVevbJL9MWIijPbCm+4FBHkUHDLAxmoqThJ/bc+UM 0JGg== X-Gm-Message-State: AE9vXwPXpJF4SLb1or1/gc+ue7dJNqv3evmIgbkmIVJrBOnv6VTX/Uz6Ptv0CYAgu4oG0A== X-Received: by 10.157.22.168 with SMTP id c37mr3183396ote.236.1473991769076; Thu, 15 Sep 2016 19:09:29 -0700 (PDT) Received: from localhost.localdomain ([181.22.35.206]) by smtp.gmail.com with ESMTPSA id n191sm5364748oig.24.2016.09.15.19.09.27 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 15 Sep 2016 19:09:28 -0700 (PDT) From: James Almer To: ffmpeg-devel@ffmpeg.org Date: Thu, 15 Sep 2016 23:08:47 -0300 Message-Id: <20160916020847.6760-1-jamrial@gmail.com> X-Mailer: git-send-email 2.9.1 Subject: [FFmpeg-devel] [PATCH] avutil/softfloat_ieee754: make all functions inline X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Removes "defined but not used" warnings Signed-off-by: James Almer --- libavutil/softfloat_ieee754.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/libavutil/softfloat_ieee754.h b/libavutil/softfloat_ieee754.h index f82397b..b8957fb 100644 --- a/libavutil/softfloat_ieee754.h +++ b/libavutil/softfloat_ieee754.h @@ -38,7 +38,7 @@ static const SoftFloat_IEEE754 FLOAT_1 = {0, 0, 0}; /** Normalize the softfloat as defined by IEEE 754 single-recision floating * point specification */ -static SoftFloat_IEEE754 av_normalize_sf_ieee754(SoftFloat_IEEE754 sf) { +static inline SoftFloat_IEEE754 av_normalize_sf_ieee754(SoftFloat_IEEE754 sf) { while( sf.mant >= 0x1000000UL ) { sf.exp++; sf.mant >>= 1; @@ -50,7 +50,7 @@ static SoftFloat_IEEE754 av_normalize_sf_ieee754(SoftFloat_IEEE754 sf) { /** Convert integer to softfloat. * @return softfloat with value n * 2^e */ -static SoftFloat_IEEE754 av_int2sf_ieee754(int64_t n, int e) { +static inline SoftFloat_IEEE754 av_int2sf_ieee754(int64_t n, int e) { int sign = 0; if (n < 0) { @@ -63,13 +63,13 @@ static SoftFloat_IEEE754 av_int2sf_ieee754(int64_t n, int e) { /** Make a softfloat out of the bitstream. Assumes the bits are in the form as defined * by the IEEE 754 spec. */ -static SoftFloat_IEEE754 av_bits2sf_ieee754(uint32_t n) { +static inline SoftFloat_IEEE754 av_bits2sf_ieee754(uint32_t n) { return ((SoftFloat_IEEE754) { (n & 0x80000000UL), (n & 0x7FFFFFUL), (n & 0x7F800000UL) }); } /** Convert the softfloat to integer */ -static int av_sf2int_ieee754(SoftFloat_IEEE754 a) { +static inline int av_sf2int_ieee754(SoftFloat_IEEE754 a) { if(a.exp >= 0) return a.mant << a.exp ; else return a.mant >>(-a.exp); } @@ -77,7 +77,7 @@ static int av_sf2int_ieee754(SoftFloat_IEEE754 a) { /** Divide a by b. b should not be zero. * @return normalized result */ -static SoftFloat_IEEE754 av_div_sf_ieee754(SoftFloat_IEEE754 a, SoftFloat_IEEE754 b) { +static inline SoftFloat_IEEE754 av_div_sf_ieee754(SoftFloat_IEEE754 a, SoftFloat_IEEE754 b) { int32_t mant, exp, sign; a = av_normalize_sf_ieee754(a); b = av_normalize_sf_ieee754(b); @@ -90,7 +90,7 @@ static SoftFloat_IEEE754 av_div_sf_ieee754(SoftFloat_IEEE754 a, SoftFloat_IEEE75 /** Multiply a with b * #return normalized result */ -static SoftFloat_IEEE754 av_mul_sf_ieee754(SoftFloat_IEEE754 a, SoftFloat_IEEE754 b) { +static inline SoftFloat_IEEE754 av_mul_sf_ieee754(SoftFloat_IEEE754 a, SoftFloat_IEEE754 b) { int32_t sign, mant, exp; a = av_normalize_sf_ieee754(a); b = av_normalize_sf_ieee754(b); @@ -103,7 +103,7 @@ static SoftFloat_IEEE754 av_mul_sf_ieee754(SoftFloat_IEEE754 a, SoftFloat_IEEE75 /** Compare a with b strictly * @returns 1 if the a and b are equal, 0 otherwise. */ -static int av_cmp_sf_ieee754(SoftFloat_IEEE754 a, SoftFloat_IEEE754 b) { +static inline int av_cmp_sf_ieee754(SoftFloat_IEEE754 a, SoftFloat_IEEE754 b) { a = av_normalize_sf_ieee754(a); b = av_normalize_sf_ieee754(b); if (a.sign != b.sign) return 0;