English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General > Coders. Tutorials

 
 
Thread Tools
Old 02 July 2024, 00:04   #161
phx
Natteravn
 
phx's Avatar
 
Join Date: Nov 2009
Location: Herford / Germany
Posts: 2,551
Quote:
Originally Posted by hop View Post
it would be preferable not to discard known symbol data from HUNK_SYMBOL if possible. The config file symbols do not have an associated section, but HUNK_SYMBOLs do, would it be possible to parse and store this information to use in this situation?
Yes, of course you can. I even wrote the code today to do that - although I think it is not worth the effort, just for a symbol at the beginning of a section which doesn't show up when the previous section is empty. How often is that a problem?

In most cases executables have neither symbols nor empty sections. And then you still have the
SECSTRT_n
label.

At the end of the day I had to realise that I still cannot determine if a label should be generated for the empty section or the following section, because the offset is identical. Label-generation is triggered by offsets stored in the
ira->LabelAdr2[]
array. And its index (
p2labind
) will be incremented as long as the current offset matches.

Nothing is impossible, and I might have another look this week, but I fear the solution of this problem would need much bigger modifications.
phx is offline  
Old 02 July 2024, 11:28   #162
kamelito
Zone Friend
 
kamelito's Avatar
 
Join Date: May 2006
Location: France
Posts: 1,861
Dunno how often but as it has been generated by an old C compiler it could be seen elsewhere I guess.
kamelito is offline  
Old 02 July 2024, 11:41   #163
hop
Registered User
 
hop's Avatar
 
Join Date: Apr 2019
Location: UK
Posts: 260
Quote:
Originally Posted by phx View Post
Yes, of course you can. I even wrote the code today to do that - although I think it is not worth the effort, just for a symbol at the beginning of a section which doesn't show up when the previous section is empty. How often is that a problem?

In most cases executables have neither symbols nor empty sections. And then you still have the
SECSTRT_n
label.

At the end of the day I had to realise that I still cannot determine if a label should be generated for the empty section or the following section, because the offset is identical. Label-generation is triggered by offsets stored in the
ira->LabelAdr2[]
array. And its index (
p2labind
) will be incremented as long as the current offset matches.

Nothing is impossible, and I might have another look this week, but I fear the solution of this problem would need much bigger modifications.
Thank you very much for taking the time to look into this. I appreciate that it is not a high-priority issue, but in the interest of correctness I think it is worth doing, if it is not too much work. As @kamelito says, this may be a feature of a common toolchain, although shipping with debug symbols in place may be less common!

Would it be possible to add another array alongside
ira->LabelAdr2[]
of equal size called something like
ira->LabelHunkIndex[]
? The elements would default to -1 (unknown hunk) but when symbols are added from a
HUNK_SYMBOL
it could be set to a valid value. Then this could be read in
WriteSection

Last edited by hop; 02 July 2024 at 11:44. Reason: typo, correction
hop is offline  
Old 02 July 2024, 11:43   #164
kamelito
Zone Friend
 
kamelito's Avatar
 
Join Date: May 2006
Location: France
Posts: 1,861
There is many games and some apps that contains symbols.
kamelito is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
ira for Windows jotd Coders. General 63 12 December 2023 10:53
New tutorial on sprites Yragael Coders. Tutorials 8 04 September 2023 21:00
Debugging messages in serial (small tutorial, mainly for cross-dev) alkis Coders. Asm / Hardware 7 22 February 2016 14:16
68020 to 68000 code convertion using Ira and PhxAss gulliver Coders. Asm / Hardware 18 12 April 2014 01:09
Looking for IRA v1.07 or newer :-) voxel request.Apps 7 30 July 2008 01:39

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 05:38.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.10748 seconds with 16 queries