compress: Change running from bitfield to plain int
PATCH 4/14 compress: Change running from bitfield to plain int
Declaring running as a single-bit bitfield does not save any space or give any coding advantages, but does leave potential opportunities for the compiler to be inefficient in how it handles bitfields compared to how it would handle a machine int.
compress.c +1 -1
@@ -82,7 +82,7 @@ struct compress {unsigned int flags;char error[COMPR_ERR_MAX ];struct compr_config *config; - int running:1; +int running; };static int oops (struct compress *compress,int e,const char *fmt, ...)
Signature · 1 line
1.7.2.5
Declaring running as a single-bit bitfield does not save any space or give any coding advantages, but does leave potential opportunities for the compiler to be inefficient in how it handles bitfields compared to how it would handle a machine int.
--- compress.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
compress.c +1 -1
@@ -82,7 +82,7 @@ struct compress {unsigned int flags;char error[COMPR_ERR_MAX ];struct compr_config *config; - unsigned int running:1; +int running; };static int oops (struct compress *compress,int e,const char *fmt, ...)
Signature · 1 line
1.7.2.5