tls: set TLS_DEBUG to 0; placate a gcc indentation warning

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko 2017-01-23 01:15:13 +01:00
parent 9a647c326a
commit 9492da7e63
2 changed files with 13 additions and 11 deletions

View File

@ -18,7 +18,7 @@
#include "tls.h" #include "tls.h"
#define TLS_DEBUG 1 #define TLS_DEBUG 0
#define TLS_DEBUG_HASH 0 #define TLS_DEBUG_HASH 0
#define TLS_DEBUG_DER 0 #define TLS_DEBUG_DER 0
#define TLS_DEBUG_FIXED_SECRETS 0 #define TLS_DEBUG_FIXED_SECRETS 0

View File

@ -27,13 +27,14 @@
static ALWAYS_INLINE unsigned ROL(unsigned word, int i) static ALWAYS_INLINE unsigned ROL(unsigned word, int i)
{ {
if (__builtin_constant_p(i)) //box if (__builtin_constant_p(i)) { //box
// Rotates by constant use fewer registers, // Rotates by constant use fewer registers,
// and on many Intel CPUs rotates by %cl take 2 cycles, not 1. // and on many Intel CPUs rotates by %cl take 2 cycles, not 1.
asm ("roll %2,%0" //box asm ("roll %2,%0"
:"=r" (word) :"=r" (word)
:"0" (word),"i" (i)); :"0" (word),"i" (i));
else //box return word;
} //box
asm ("roll %%cl,%0" asm ("roll %%cl,%0"
:"=r" (word) :"=r" (word)
:"0" (word),"c" (i)); :"0" (word),"c" (i));
@ -42,11 +43,12 @@ static ALWAYS_INLINE unsigned ROL(unsigned word, int i)
static ALWAYS_INLINE unsigned ROR(unsigned word, int i) static ALWAYS_INLINE unsigned ROR(unsigned word, int i)
{ {
if (__builtin_constant_p(i)) //box if (__builtin_constant_p(i)) { //box
asm ("rorl %2,%0" //box asm ("rorl %2,%0"
:"=r" (word) :"=r" (word)
:"0" (word),"i" (i)); :"0" (word),"i" (i));
else //box return word;
} //box
asm ("rorl %%cl,%0" asm ("rorl %%cl,%0"
:"=r" (word) :"=r" (word)
:"0" (word),"c" (i)); :"0" (word),"c" (i));