Skip to content

Commit 555b548

Browse files
committed
Release 1.0.18
* Fixed compilation regression for 32-bit Clang compiler.
2 parents 65807ff + fc03c59 commit 555b548

File tree

5 files changed

+21
-23
lines changed

5 files changed

+21
-23
lines changed

CHANGELOG

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
* RECENT CHANGES
33
*******************************************************************************
44

5+
=== 1.0.18 ===
6+
* Fixed compilation regression for 32-bit Clang compiler.
7+
58
=== 1.0.17 ===
69
* Implemented SIMD-optimized 2-knee compressor curve and gain calculation functions.
710
* Implemented several AVX-512 optimized packed complex functions.

include/lsp-plug.in/dsp/version.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
// Define version of headers
2626
#define LSP_DSP_LIB_MAJOR 1
2727
#define LSP_DSP_LIB_MINOR 0
28-
#define LSP_DSP_LIB_MICRO 17
28+
#define LSP_DSP_LIB_MICRO 18
2929

3030
#if defined(__WINDOWS__) || defined(__WIN32__) || defined(__WIN64__) || defined(_WIN64) || defined(_WIN32) || defined(__WINNT) || defined(__WINNT__)
3131
#define LSP_DSP_LIB_EXPORT_MODIFIER __declspec(dllexport)

include/private/dsp/arch/x86/sse/complex.h

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ namespace lsp
261261
(
262262
COMPLEX_DIV2_CORE("dst_re", "dst_im", "dst_re", "dst_im", "src_re", "src_im")
263263
: [off] "=&r" (off),
264-
[count] __ASM_ARG_RW(count)
264+
[count] X86_PGREG(count)
265265
: [dst_re] "r" (dst_re), [dst_im] "r" (dst_im),
266266
[src_re] "r" (src_re), [src_im] "r" (src_im),
267267
[CC] "o" (complex_div_const)
@@ -278,7 +278,7 @@ namespace lsp
278278
(
279279
COMPLEX_DIV2_CORE("dst_re", "dst_im", "src_re", "src_im", "dst_re", "dst_im")
280280
: [off] "=&r" (off),
281-
[count] __ASM_ARG_RW(count)
281+
[count] X86_PGREG(count)
282282
: [dst_re] "r" (dst_re), [dst_im] "r" (dst_im),
283283
[src_re] "r" (src_re), [src_im] "r" (src_im),
284284
[CC] "o" (complex_div_const)
@@ -298,7 +298,8 @@ namespace lsp
298298
(
299299
__ASM_EMIT ("xor %[off], %[off]")
300300
// x4 blocks
301-
__ASM_EMIT ("sub $4, %[count]")
301+
__ASM_EMIT32("subl $4, %[count]") \
302+
__ASM_EMIT64("sub $4, %[count]") \
302303
__ASM_EMIT ("jb 2f")
303304
__ASM_EMIT ("1:")
304305
__ASM_EMIT32("mov %[t_re], %[ptr_re]")
@@ -333,11 +334,13 @@ namespace lsp
333334
__ASM_EMIT64("movups %%xmm0, 0x00(%[dst_re], %[off])")
334335
__ASM_EMIT64("movups %%xmm1, 0x00(%[dst_im], %[off])")
335336
__ASM_EMIT ("add $0x10, %[off]")
336-
__ASM_EMIT ("sub $4, %[count]")
337+
__ASM_EMIT32("subl $4, %[count]") \
338+
__ASM_EMIT64("sub $4, %[count]") \
337339
__ASM_EMIT ("jae 1b")
338340
__ASM_EMIT ("2:")
339341
// x1 blocks
340-
__ASM_EMIT ("add $3, %[count]")
342+
__ASM_EMIT32("addl $3, %[count]") \
343+
__ASM_EMIT64("add $3, %[count]") \
341344
__ASM_EMIT ("jl 4f")
342345
__ASM_EMIT ("3:")
343346
__ASM_EMIT32("mov %[t_re], %[ptr_re]")
@@ -372,15 +375,16 @@ namespace lsp
372375
__ASM_EMIT64("movss %%xmm0, 0x00(%[dst_re], %[off])")
373376
__ASM_EMIT64("movss %%xmm1, 0x00(%[dst_im], %[off])")
374377
__ASM_EMIT ("add $0x04, %[off]")
375-
__ASM_EMIT ("dec %[count]")
378+
__ASM_EMIT32("decl %[count]") \
379+
__ASM_EMIT64("dec %[count]") \
376380
__ASM_EMIT ("jge 3b")
377381
__ASM_EMIT ("4:")
378382
/* end */
379383

380384
: __IF_32(
381385
[ptr_re] "=&r" (ptr_re), [ptr_im] "=&r" (ptr_im),
382386
)
383-
[count] "+r" (count), [off] "=&r" (off)
387+
[count] X86_PGREG(count), [off] "=&r" (off)
384388
: [dst_re] X86_GREG (dst_re), [dst_im] X86_GREG (dst_im),
385389
[t_re] X86_GREG (t_re), [t_im] X86_GREG (t_im),
386390
[b_re] "r" (b_re), [b_im] "r" (b_im),

include/private/dsp/arch/x86/sse2/dynamics/compressor.h

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,7 @@ namespace lsp
197197
IF_ARCH_X86(
198198
comp_knee_t knee[2] __lsp_aligned16;
199199
float mem[24] __lsp_aligned16;
200+
float stub[4] __lsp_aligned16;
200201
size_t mask;
201202
);
202203

@@ -259,6 +260,7 @@ namespace lsp
259260
: [comp] "r" (c),
260261
[knee] "o" (knee),
261262
[mem] "o" (mem),
263+
[stub] "o" (stub),
262264
[C2C] "o" (compressor_const),
263265
[L2C] "o" (LOG2_CONST),
264266
[LOGC] "o" (LOGE_C),
@@ -275,22 +277,10 @@ namespace lsp
275277
IF_ARCH_X86(
276278
comp_knee_t knee[2] __lsp_aligned16;
277279
float mem[24] __lsp_aligned16;
280+
float stub[4] __lsp_aligned16;
278281
size_t mask;
279282
);
280-
// for (size_t i=0; i<count; ++i)
281-
// {
282-
// float x = fabsf(src[i]);
283-
// float lx = logf(x);
284-
//
285-
// float g1 = (x <= c->k[0].start) ? c->k[0].gain :
286-
// (x >= c->k[0].end) ? expf(lx * c->k[0].tilt[0] + c->k[0].tilt[1]) :
287-
// expf((c->k[0].herm[0]*lx + c->k[0].herm[1])*lx + c->k[0].herm[2]);
288-
// float g2 = (x <= c->k[1].start) ? c->k[1].gain :
289-
// (x >= c->k[1].end) ? expf(lx * c->k[1].tilt[0] + c->k[1].tilt[1]) :
290-
// expf((c->k[1].herm[0]*lx + c->k[1].herm[1])*lx + c->k[1].herm[2]);
291-
//
292-
// dst[i] = g1 * g2 * x;
293-
// }
283+
294284
ARCH_X86_ASM
295285
(
296286
// Prepare stuff
@@ -358,6 +348,7 @@ namespace lsp
358348
: [comp] "r" (c),
359349
[knee] "o" (knee),
360350
[mem] "o" (mem),
351+
[stub] "o" (stub),
361352
[C2C] "o" (compressor_const),
362353
[L2C] "o" (LOG2_CONST),
363354
[LOGC] "o" (LOGE_C),

project.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,4 @@ ARTIFACT_ID = LSP_DSP_LIB
2323
ARTIFACT_NAME = lsp-dsp-lib
2424
ARTIFACT_DESC = DSP library for digital signal processing
2525
ARTIFACT_HEADERS = lsp-plug.in
26-
ARTIFACT_VERSION = 1.0.17
26+
ARTIFACT_VERSION = 1.0.18

0 commit comments

Comments
 (0)