Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
fast-crc32c
Advanced tools
Readme
fast-crc32c is a CRC-32C algorithm implementation for node.js, which uses hardware acceleration (via voxer/sse4_crc32 by Anand Suresh), and fallback to software implementation when hardware acceleration fails.
CRC-32C is faster then CRC-32, which could take advantage of full CPU operand register width (64bit) instead of CRC-32's 8bit.
When using hardware acceleration, CRC-32C is about 7x ~ 9x faster than software implemented CRC-32C.
The 3 tested implementations are:
$ yarn run benchmark
yarn run v1.17.3
$ node benchmark
sse4_crc32c_hw for inputs 1024B x 3,210,508 ops/sec ±2.09% (87 runs sampled)
sse4_crc32c_hw for inputs 16836819B, avg 2055B x 252 ops/sec ±2.90% (79 runs sampled)
sse4_crc32c_sw for inputs 1024B x 1,358,720 ops/sec ±1.31% (89 runs sampled)
sse4_crc32c_sw for inputs 16836819B, avg 2055B x 96.41 ops/sec ±1.42% (71 runs sampled)
js_crc32c for inputs 1024B x 409,615 ops/sec ±1.46% (89 runs sampled)
js_crc32c for inputs 16836819B, avg 2055B x 26.00 ops/sec ±0.72% (47 runs sampled)
js_crc32 for inputs 1024B x 403,262 ops/sec ±1.55% (90 runs sampled)
js_crc32 for inputs 16836819B, avg 2055B x 24.82 ops/sec ±1.70% (45 runs sampled)
1024B | 16836819B, avg 2055B | |
---|---|---|
sse4_crc32c_hw | 3,210,508 ops/sec | 252 ops/sec |
sse4_crc32c_sw | 1,358,720 ops/sec | 96.41 ops/sec |
js_crc32c | 409,615 ops/sec | 26.00 ops/sec |
js_crc32 | 403,262 ops/sec | 24.82 ops/sec |
npm install fast-crc32c@^2.0.0 --save
# For node version before 6
# npm install fast-crc32c@^1.0.0 --save
var crc32 = require('fast-crc32c');
var result = crc32.calculate(data, initial);
FAQs
CRC32C algorithm with hardware acceleration and software fallback.
The npm package fast-crc32c receives a total of 48,557 weekly downloads. As such, fast-crc32c popularity was classified as popular.
We found that fast-crc32c demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.