libsquashfs: sqfs_block_processor_desc_t Struct Reference

libsquashfs 1.3.2 A new set of tools and libraries for working with SquashFS images

Loading...
Searching...
No Matches
sqfs_block_processor_desc_t Struct Reference

Encapsulates a description for an sqfs_block_processor_t. More...

`#include <block_processor.h>`

Collaboration diagram for sqfs_block_processor_desc_t:

## Data Fields
sqfs_u32 | size
| Holds the size of the structure.
sqfs_u32 | max_block_size
| The maximum size of a data block.
sqfs_u32 | num_workers
| The number of worker threads to create.
sqfs_u32 | max_backlog
| The maximum number of blocks currently in flight.
sqfs_compressor_t * | cmp
| A pointer to a compressor.
sqfs_block_writer_t * | wr
| A block writer to send to finished blocks to.
sqfs_frag_table_t * | tbl
| A fragment table to use for storing block locations.
sqfs_file_t * | file
| Pointer to a file to read back fragment blocks from.
sqfs_compressor_t * | uncmp
| A pointer to a compressor the decompresses data.

## Detailed Description

Encapsulates a description for an sqfs_block_processor_t.

An instance of this struct is used by sqfs_block_processor_create_ex to instantiate block processor objects.

Definition at line 121 of file block_processor.h.

## Field Documentation

## ◆ cmp

sqfs_compressor_t* cmp

A pointer to a compressor.

If multiple worker threads are used, the deep copy function of the compressor is used to create several instances that don't interfere with each other. This means, the compressor implementation must be able to create copies of itself that can be used independendly and concurrently.

Definition at line 161 of file block_processor.h.

## ◆ file

sqfs_file_t* file

Pointer to a file to read back fragment blocks from.

If file and uncmp are not NULL, the file is used to read back fragment blocks during fragment deduplication and verify possible matches. If either of them are NULL, the deduplication relies on fragment size and hash alone.

Definition at line 181 of file block_processor.h.

## ◆ max_backlog

sqfs_u32 max_backlog

The maximum number of blocks currently in flight.

When trying to add more, enqueueing blocks until the in-flight block count drops below the threshold.

Definition at line 150 of file block_processor.h.

## ◆ max_block_size

sqfs_u32 max_block_size

The maximum size of a data block.

Definition at line 137 of file block_processor.h.

## ◆ num_workers

sqfs_u32 num_workers

The number of worker threads to create.

Definition at line 142 of file block_processor.h.

## ◆ size

sqfs_u32 size

Holds the size of the structure.

If a later version of libsquashfs expands this structure, the value of this field can be used to check at runtime whether the newer fields are avaialable or not.

If sqfs_block_processor_create_ex is given a struct whose size it does not recognize, it returns SQFS_ERROR_ARG_INVALID.

Definition at line 132 of file block_processor.h.

## ◆ tbl

sqfs_frag_table_t* tbl

A fragment table to use for storing block locations.

Definition at line 171 of file block_processor.h.

## ◆ uncmp

sqfs_compressor_t* uncmp

A pointer to a compressor the decompresses data.

Pointer to a file to read back fragment blocks from.

If file and uncmp are not NULL, the file is used to read back fragment blocks during fragment deduplication and verify possible matches. If either of them are NULL, the deduplication relies on fragment size and hash alone.

Definition at line 188 of file block_processor.h.

## ◆ wr

sqfs_block_writer_t* wr

A block writer to send to finished blocks to.

Definition at line 166 of file block_processor.h.

The documentation for this struct was generated from the following file:

- include/sqfs/block_processor.h