Skip to content

Commit

Permalink
Merge pull request #7 from starbelly/move-to-dirty-schedulers
Browse files Browse the repository at this point in the history
Run nif functions on dirty schedulers (cpu bound)
  • Loading branch information
zmstone authored Jul 1, 2024
2 parents 4dcc049 + 63842e8 commit 35fc117
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions c_src/snappyer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -267,10 +267,10 @@ on_upgrade(ErlNifEnv* env, void** priv, void** old_priv, ERL_NIF_TERM info)


static ErlNifFunc nif_functions[] = {
{"compress", 1, snappy_compress_erl},
{"decompress", 1, snappy_decompress_erl},
{"uncompressed_length", 1, snappy_uncompressed_length_erl},
{"is_valid", 1, snappy_is_valid}
{"compress", 1, snappy_compress_erl, ERL_NIF_DIRTY_JOB_CPU_BOUND},
{"decompress", 1, snappy_decompress_erl, ERL_NIF_DIRTY_JOB_CPU_BOUND},
{"uncompressed_length", 1, snappy_uncompressed_length_erl, ERL_NIF_DIRTY_JOB_CPU_BOUND},
{"is_valid", 1, snappy_is_valid, ERL_NIF_DIRTY_JOB_CPU_BOUND}
};


Expand Down

0 comments on commit 35fc117

Please sign in to comment.