8000 add "configure" operation by jcupitt · Pull Request #2753 · libvips/libvips · GitHub
[go: up one dir, main page]

Skip to content

add "configure" operation #2753

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 6 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
start adding some more configure options
  • Loading branch information
jcupitt committed Apr 12, 2022
commit 096bba949dfb7076a34bb02f950e42be0cba66d6
47 changes: 45 additions & 2 deletions libvips/iofuncs/configure.c
Original file line number Diff line number Diff line change
Expand Up @@ -146,25 +146,68 @@ vips_configure_class_init( VipsConfigureClass *class )
G_STRUCT_OFFSET( VipsConfigure, untrusted_block ),
FALSE );

VIPS_ARG_STRING( class, "operation_block", 2,
VIPS_ARG_STRING( class, "operation_block", 3,
_( "Block operation" ),
_( "Block an operation (and any subclasses) from running" ),
VIPS_ARGUMENT_OPTIONAL_INPUT,
G_STRUCT_OFFSET( VipsConfigure, operation_block ),
NULL );

VIPS_ARG_STRING( class, "operation_unblock", 2,
VIPS_ARG_STRING( class, "operation_unblock", 4,
_( "Unblock operation" ),
_( "Unblock an operation (and any subclasses) from running" ),
VIPS_ARGUMENT_OPTIONAL_INPUT,
G_STRUCT_OFFSET( VipsConfigure, operation_unblock ),
NULL );

VIPS_ARG_BOOL( class, "leak", 5,
_( "Leak" ),
_( "Report any leaks on exit" ),
VIPS_ARGUMENT_OPTIONAL_INPUT,
G_STRUCT_OFFSET( VipsConfigure, leak ),
FALSE );

VIPS_ARG_BOOL( class, "profile", 5,
_( "Profile" ),
_( "Write profiling data on exit" ),
VIPS_ARGUMENT_OPTIONAL_INPUT,
G_STRUCT_OFFSET( VipsConfigure, profile ),
FALSE );

VIPS_ARG_INT( class, "concurrency", 5,
_( "Concurrency" ),
_( "Set threadpool size" ),
VIPS_ARGUMENT_OPTIONAL_INPUT,
G_STRUCT_OFFSET( VipsConfigure, concurrency ),
-1 );


/* Max size of pipe.
*/
int64 pipe_read_limit;

/* Trace libvips operation cache actions.
*/
gboolean cache_trace;

/* Number of recent operations to cache.< 8000 /span>
*/
int cache_max;

/* Maximum memory to use for operation caching.
*/
int64 cache_max_mem;

/* Maximum number of open files we allow in the cache.
*/
int cache_max_files;

}

static void
vips_configure_init( VipsConfigure *configure )
{
configure->concurrency = -1;
}

/**
Expand Down
1 change: 0 additions & 1 deletion libvips/iofuncs/source.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* A byte source/sink .. it can be a pipe, file descriptor, memory area,
* socket, node.js stream, etc.
*
* 19/6/14
Expand Down
0