Bugzilla – Attachment 217 Details for
Bug 224
Small bug in 56k code generation
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
The patches!
0001-Fix-for-issue-224-56k-short-immediate-value-was-not-.patch (text/plain), 975 bytes, created by
ggn
on 2023-12-22 11:53:12 CST
(
hide
)
Description:
The patches!
Filename:
MIME Type:
Creator:
ggn
Created:
2023-12-22 11:53:12 CST
Size:
975 bytes
patch
obsolete
>From 48f0a332bb0d15408a24d8e461a28a34421dc8d8 Mon Sep 17 00:00:00 2001 >From: ggn <ggn@atari.org> >Date: Fri, 22 Dec 2023 19:50:18 +0200 >Subject: [PATCH] Fix for issue #224 - 56k short immediate value was not > clamped, so negatives would corrupt the opcode > >--- > dsp56k_amode.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/dsp56k_amode.c b/dsp56k_amode.c >index 664c533..b916eec 100644 >--- a/dsp56k_amode.c >+++ b/dsp56k_amode.c >@@ -2603,11 +2603,11 @@ deposit_immediate_long_with_register: > return inst; > } > >- if (((int32_t)dspImmedEXVAL < 0x100) && ((int32_t)dspImmedEXVAL >= -0x100)) >+ if (dspImmedEXVAL + 0x100 < 0x200) > { > // value fits in 8 bits - immediate move > deposit_immediate_short_with_register: >- inst = 0b0010000000000000 + (immreg << 8) + (uint32_t)dspImmedEXVAL; >+ inst = 0b0010000000000000 + (immreg << 8) | (uint8_t)dspImmedEXVAL; > return inst; > } > else >-- >2.40.1.windows.1 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 224
: 217