Print this page
4045 zfs write throttle & i/o scheduler performance work
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Adam Leventhal <ahl@delphix.com>
Reviewed by: Christopher Siden <christopher.siden@delphix.com>


 203         DMU_OT_NUMTYPES,
 204 
 205         /*
 206          * Names for valid types declared with DMU_OT().
 207          */
 208         DMU_OTN_UINT8_DATA = DMU_OT(DMU_BSWAP_UINT8, B_FALSE),
 209         DMU_OTN_UINT8_METADATA = DMU_OT(DMU_BSWAP_UINT8, B_TRUE),
 210         DMU_OTN_UINT16_DATA = DMU_OT(DMU_BSWAP_UINT16, B_FALSE),
 211         DMU_OTN_UINT16_METADATA = DMU_OT(DMU_BSWAP_UINT16, B_TRUE),
 212         DMU_OTN_UINT32_DATA = DMU_OT(DMU_BSWAP_UINT32, B_FALSE),
 213         DMU_OTN_UINT32_METADATA = DMU_OT(DMU_BSWAP_UINT32, B_TRUE),
 214         DMU_OTN_UINT64_DATA = DMU_OT(DMU_BSWAP_UINT64, B_FALSE),
 215         DMU_OTN_UINT64_METADATA = DMU_OT(DMU_BSWAP_UINT64, B_TRUE),
 216         DMU_OTN_ZAP_DATA = DMU_OT(DMU_BSWAP_ZAP, B_FALSE),
 217         DMU_OTN_ZAP_METADATA = DMU_OT(DMU_BSWAP_ZAP, B_TRUE),
 218 } dmu_object_type_t;
 219 
 220 typedef enum txg_how {
 221         TXG_WAIT = 1,
 222         TXG_NOWAIT,

 223 } txg_how_t;
 224 
 225 void byteswap_uint64_array(void *buf, size_t size);
 226 void byteswap_uint32_array(void *buf, size_t size);
 227 void byteswap_uint16_array(void *buf, size_t size);
 228 void byteswap_uint8_array(void *buf, size_t size);
 229 void zap_byteswap(void *buf, size_t size);
 230 void zfs_oldacl_byteswap(void *buf, size_t size);
 231 void zfs_acl_byteswap(void *buf, size_t size);
 232 void zfs_znode_byteswap(void *buf, size_t size);
 233 
 234 #define DS_FIND_SNAPSHOTS       (1<<0)
 235 #define DS_FIND_CHILDREN        (1<<1)
 236 
 237 /*
 238  * The maximum number of bytes that can be accessed as part of one
 239  * operation, including metadata.
 240  */
 241 #define DMU_MAX_ACCESS (10<<20) /* 10MB */
 242 #define DMU_MAX_DELETEBLKCNT (20480) /* ~5MB of indirect blocks */




 203         DMU_OT_NUMTYPES,
 204 
 205         /*
 206          * Names for valid types declared with DMU_OT().
 207          */
 208         DMU_OTN_UINT8_DATA = DMU_OT(DMU_BSWAP_UINT8, B_FALSE),
 209         DMU_OTN_UINT8_METADATA = DMU_OT(DMU_BSWAP_UINT8, B_TRUE),
 210         DMU_OTN_UINT16_DATA = DMU_OT(DMU_BSWAP_UINT16, B_FALSE),
 211         DMU_OTN_UINT16_METADATA = DMU_OT(DMU_BSWAP_UINT16, B_TRUE),
 212         DMU_OTN_UINT32_DATA = DMU_OT(DMU_BSWAP_UINT32, B_FALSE),
 213         DMU_OTN_UINT32_METADATA = DMU_OT(DMU_BSWAP_UINT32, B_TRUE),
 214         DMU_OTN_UINT64_DATA = DMU_OT(DMU_BSWAP_UINT64, B_FALSE),
 215         DMU_OTN_UINT64_METADATA = DMU_OT(DMU_BSWAP_UINT64, B_TRUE),
 216         DMU_OTN_ZAP_DATA = DMU_OT(DMU_BSWAP_ZAP, B_FALSE),
 217         DMU_OTN_ZAP_METADATA = DMU_OT(DMU_BSWAP_ZAP, B_TRUE),
 218 } dmu_object_type_t;
 219 
 220 typedef enum txg_how {
 221         TXG_WAIT = 1,
 222         TXG_NOWAIT,
 223         TXG_WAITED,
 224 } txg_how_t;
 225 
 226 void byteswap_uint64_array(void *buf, size_t size);
 227 void byteswap_uint32_array(void *buf, size_t size);
 228 void byteswap_uint16_array(void *buf, size_t size);
 229 void byteswap_uint8_array(void *buf, size_t size);
 230 void zap_byteswap(void *buf, size_t size);
 231 void zfs_oldacl_byteswap(void *buf, size_t size);
 232 void zfs_acl_byteswap(void *buf, size_t size);
 233 void zfs_znode_byteswap(void *buf, size_t size);
 234 
 235 #define DS_FIND_SNAPSHOTS       (1<<0)
 236 #define DS_FIND_CHILDREN        (1<<1)
 237 
 238 /*
 239  * The maximum number of bytes that can be accessed as part of one
 240  * operation, including metadata.
 241  */
 242 #define DMU_MAX_ACCESS (10<<20) /* 10MB */
 243 #define DMU_MAX_DELETEBLKCNT (20480) /* ~5MB of indirect blocks */