Yann Collet
aa787570e6
Windows CI: test lz4 -l on an empty file, NEWS for #1740
...
On Windows, TPool_jobsCompleted() only waited on an auto-reset event,
set when the pending job count drops to 0 :
- with no job submitted, the event is never set and the wait never ends.
`lz4 -l` on an empty file submits no write job,
and decoding the resulting stream (magic number only) submits no decoding job.
- ResetEvent() + increment in TPool_submitJob() race with
decrement + SetEvent() in a worker : the event can stay set while a job
is still pending, so the wait could end before the last write.
#1740 checks the pending job count before waiting, and after each wake up.
The Windows CI never ran lz4 on files :
_test.bat now compresses and decodes an empty file in legacy format.
2026-10-17 09:01:28 -07:00
jmestwa-coder
adbf1719e7
avoid hang by using predicate-based wait in TPool_jobsCompleted
2026-06-08 10:28:32 +05:30
Yann Collet
2719f42eb5
removed year from header ( #1605 )
...
as it's a burden to maintain, and wasn't consistently updated.
Now rely on git dating.
2025-04-27 10:55:25 -08:00
Yann Collet
461881cf4a
fixed c90 compliance
2024-07-08 02:47:08 +02:00
Yann Collet
32f7fd3f38
minor completion port update
...
for consistency with pthread implementation
2024-07-07 13:59:44 -07:00
Yann Collet
cfdb8ac60b
completion ports: minor readability refactor
2024-07-07 13:35:52 -07:00
Yann Collet
c688b4bd58
updated threadpool API
2024-07-07 13:22:46 -07:00
Yann Collet
50d541f9e3
simpler execution expression
2024-07-07 11:57:14 -07:00
Yann Collet
f0b29a973b
updated completion ports logic
...
jobSlotAvail control job queue size,
end of jobs wait on a single event, instead of busy looping.
2024-07-07 11:45:22 -07:00
Yann Collet
1dc60aa1a2
minor: removed one variable
2024-07-07 09:08:14 -07:00
Yann Collet
79e72beeb5
minor optimization: allocate worker array at runtime
...
this makes it possible to increase LZ4_NBWORKERS_MAX without memory cost
2024-07-06 04:05:28 -07:00
Yann Collet
b5639ade0e
fixed Visual Studio type warning
2024-07-06 01:36:19 -07:00
Yann Collet
10cc4e38ac
fix C90 comment style
2024-07-05 18:25:48 -07:00
Yann Collet
c7fd52aebc
fixed queue size control
2024-07-05 17:38:14 -07:00
Yann Collet
3628163d2a
minor: Semaphore init value
2024-07-05 17:16:27 -07:00
Yann Collet
097f0fba84
minor parameter sanitization
2024-07-05 17:11:35 -07:00
Yann Collet
b4e3708823
queueLock no longer required
2024-07-05 16:45:07 -07:00
Yann Collet
7183fe9e04
minor simplification
...
less use of critical section
2024-07-05 14:57:03 -07:00
Yann Collet
9443ed9332
working implementation of completionPorts
...
to support multithreading and asyncio on Windows
2024-07-05 14:33:14 -07:00
Yann Collet
7a1b70502a
fix variable LZ4IO_MULTITHREAD
2024-03-10 17:57:26 -07:00
Yann Collet
1230f1ca61
regrouped all compile-time variables into programs/lz4conf.h
...
also:
updated naming scheme for better consistency
2024-01-01 09:49:22 -08:00
Yann Collet
d61b4f1fe2
LZ4IO_MULTITHREADING can be forcefully disabled at compile time
2023-12-31 15:55:53 -08:00
Yann Collet
cbe7211b9c
make: fix lz4 mt compilation on linux/posix
...
now lz4 build defaults to single-thread mode
2023-12-28 16:26:01 -08:00
Yann Collet
b239d6afef
added a simple (untested) threadpool implementation
2023-12-27 23:32:37 -08:00