Эх сурвалжийг харах

ncd: NCDModule: use bitfields for state and error flag in NCDModuleInst. Provides a small performance boost.

ambrop7 13 жил өмнө
parent
commit
4c6064a80e
1 өөрчлөгдсөн 2 нэмэгдсэн , 2 устгасан
  1. 2 2
      ncd/NCDModule.h

+ 2 - 2
ncd/NCDModule.h

@@ -344,8 +344,8 @@ typedef struct NCDModuleInst_s {
     const struct NCDModule *m;
     const struct NCDModuleInst_params *params;
     void *mem;
-    int state;
-    int is_error;
+    unsigned int state:3;
+    unsigned int is_error:1;
     DebugObject d_obj;
 } NCDModuleInst;