Skip to content

Commit

Permalink
rebuilt libmpg123 for win64 (x64) after applying an asm bug fix from …
Browse files Browse the repository at this point in the history
…mainstream.
  • Loading branch information
sezero committed Jul 16, 2020
1 parent 4247f06 commit 66b6dde
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 21 deletions.
Binary file modified VisualC/external/lib/x64/libmpg123-0.dll
Binary file not shown.
2 changes: 2 additions & 0 deletions external/libmpg123/NEWS
Expand Up @@ -8,6 +8,8 @@

1.22.x-sezero (backports)
---
- Fix accurate (--enable-int-quality) and s32 x86-64 assembly for Windows ABI
(thanks to Robert Kausch of fre:ac). The accurate code just crashed before.
- Make mpg123_resize_string() terminate the string if shrinking (fill now
limited to new size).
- Reset the flag for having a frame to decode before trying to
Expand Down
3 changes: 3 additions & 0 deletions external/libmpg123/src/reader.h
Expand Up @@ -80,6 +80,9 @@ struct reader_data
};

/* start to use off_t to properly do LFS in future ... used to be long */
#ifdef __MORPHOS__
#undef tell /* unistd.h defines it as lseek(x, 0L, 1) */
#endif
struct reader
{
int (*init) (mpg123_handle *);
Expand Down
22 changes: 11 additions & 11 deletions external/libmpg123/src/synth_stereo_x86_64_accurate.S
Expand Up @@ -82,7 +82,7 @@ ASM_NAME(synth_1to1_s_x86_64_accurate_asm):
#ifdef IS_MSABI
shlq $32, %rax
shrq $30, %rax
movq %rcx, %rbx
movq %rcx, %rsi
#else
movq %r8, %rax
shlq $32, %rax
Expand Down Expand Up @@ -434,16 +434,16 @@ ASM_NAME(synth_1to1_s_x86_64_accurate_asm):
andl $0xffff, %eax

#ifdef IS_MSABI
movaps (%rsp), %xmm6
movaps 16(%rsp), %xmm7
movaps 32(%rsp), %xmm8
movaps 48(%rsp), %xmm9
movaps 64(%rsp), %xmm10
movaps 80(%rsp), %xmm11
movaps 96(%rsp), %xmm12
movaps 112(%rsp), %xmm13
movaps 128(%rsp), %xmm14
movaps 144(%rsp), %xmm15
movaps 16(%rsp), %xmm6
movaps 32(%rsp), %xmm7
movaps 48(%rsp), %xmm8
movaps 64(%rsp), %xmm9
movaps 80(%rsp), %xmm10
movaps 96(%rsp), %xmm11
movaps 112(%rsp), %xmm12
movaps 128(%rsp), %xmm13
movaps 144(%rsp), %xmm14
movaps 160(%rsp), %xmm15
addq $176, %rsp
popq %rsi
#else
Expand Down
20 changes: 10 additions & 10 deletions external/libmpg123/src/synth_stereo_x86_64_s32.S
Expand Up @@ -452,16 +452,16 @@ ASM_NAME(synth_1to1_s32_s_x86_64_asm):
andl $0xffff, %eax

#ifdef IS_MSABI
movaps (%rsp), %xmm6
movaps 16(%rsp), %xmm7
movaps 32(%rsp), %xmm8
movaps 48(%rsp), %xmm9
movaps 64(%rsp), %xmm10
movaps 80(%rsp), %xmm11
movaps 96(%rsp), %xmm12
movaps 112(%rsp), %xmm13
movaps 128(%rsp), %xmm14
movaps 144(%rsp), %xmm15
movaps 16(%rsp), %xmm6
movaps 32(%rsp), %xmm7
movaps 48(%rsp), %xmm8
movaps 64(%rsp), %xmm9
movaps 80(%rsp), %xmm10
movaps 96(%rsp), %xmm11
movaps 112(%rsp), %xmm12
movaps 128(%rsp), %xmm13
movaps 144(%rsp), %xmm14
movaps 160(%rsp), %xmm15
addq $184, %rsp
popq %rdi
popq %rsi
Expand Down

0 comments on commit 66b6dde

Please sign in to comment.