[z88dk-dev] z80asm -g

Bridge to the z88dk-developers mailing list
Post Reply
alvin
Well known member
Posts: 1872
Joined: Mon Jul 16, 2007 7:39 pm

[z88dk-dev] z80asm -g

Post by alvin »

Paulo is "-g" implemented in z80asm currently? It's the option that's supposed to create a file of defc for global symbols.



------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/ ... stg.clktrk
pscust
Well known member
Posts: 194
Joined: Thu Jun 23, 2011 3:34 pm

Post by pscust »

Yes. It's either -g or --globaldef and generates a .def file with DEFC
statements.

On Sat, Feb 21, 2015 at 5:39 PM, alvin (alvin_albrecht@...) <
lists@...> wrote:
Paulo is "-g" implemented in z80asm currently? It's the option that's
supposed to create a file of defc for global symbols.




------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE

http://pubads.g.doubleclick.net/gampad/ ... stg.clktrk
pscust
Well known member
Posts: 194
Joined: Thu Jun 23, 2011 3:34 pm

Post by pscust »

Yes. It's either -g or --globaldef and generates a .def file with DEFC
statements.

On Sat, Feb 21, 2015 at 5:39 PM, alvin (alvin_albrecht@...) <
lists@...> wrote:
Paulo is "-g" implemented in z80asm currently? It's the option that's
supposed to create a file of defc for global symbols.




------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE

http://pubads.g.doubleclick.net/gampad/ ... stg.clktrk
alvin
Well known member
Posts: 1872
Joined: Mon Jul 16, 2007 7:39 pm

Post by alvin »

The global defs file and the symbol were both being left in the temp directory. I updated zcc to add a "-g" option at the linker stage and copy both the global defs file and symbols file to the target directory at compile end.



------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/ ... stg.clktrk
pscust
Well known member
Posts: 194
Joined: Thu Jun 23, 2011 3:34 pm

Post by pscust »

I noticed that zcc still has referenced to the -sdcc and -forcexlib
options. Are these still necessary?

-forcexlib is a no-op now and should be removed, as the module name is no
longer used as the symbol to force the link of a library module.

-sdcc is forcing z80asm to look-up symbols first as written in the asm
file, and then with a leading underscore, i.e. first 'main' and then, if
the first fails, '_main'.

On Sun, Feb 22, 2015 at 6:19 AM, alvin (alvin_albrecht@...) <
lists@...> wrote:
The global defs file and the symbol were both being left in the temp
directory. I updated zcc to add a "-g" option at the linker stage and copy
both the global defs file and symbols file to the target directory at
compile end.




------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE

http://pubads.g.doubleclick.net/gampad/ ... stg.clktrk
pscust
Well known member
Posts: 194
Joined: Thu Jun 23, 2011 3:34 pm

Post by pscust »

I noticed that zcc still has referenced to the -sdcc and -forcexlib
options. Are these still necessary?

-forcexlib is a no-op now and should be removed, as the module name is no
longer used as the symbol to force the link of a library module.

-sdcc is forcing z80asm to look-up symbols first as written in the asm
file, and then with a leading underscore, i.e. first 'main' and then, if
the first fails, '_main'.

On Sun, Feb 22, 2015 at 6:19 AM, alvin (alvin_albrecht@...) <
lists@...> wrote:
The global defs file and the symbol were both being left in the temp
directory. I updated zcc to add a "-g" option at the linker stage and copy
both the global defs file and symbols file to the target directory at
compile end.




------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE

http://pubads.g.doubleclick.net/gampad/ ... stg.clktrk
alvin
Well known member
Posts: 1872
Joined: Mon Jul 16, 2007 7:39 pm

Post by alvin »

> I noticed that zcc still has referenced to the -sdcc and -forcexlib options. Are these still necessary?

> -forcexlib is a no-op now and should be removed, as the module name is no longer used as the symbol to force the link of a library module.

well we can probably remove that then.

> -sdcc is forcing z80asm to look-up symbols first as written in the asm file, and then with a leading underscore, i.e. first 'main' and then, if the first fails, '_main'.

It doesn't have anything to do with accepting non-standard mnemonics like "xor a,a", etc?

The new clib does not require the extra underscore lookup but making the existing library compatible via shortcut may. The existing library will never be replaced, I think, simply because it probably results in smaller binaries for stdio and at the moment it contains a lot of specialized libraries that are not available in the new clib.

I'm not sure how successful that shortcut would be since I think there would still be problems but that idea hasn't gone away yet. I think the method used in the new clib is the way to go with the existing library too, namely we separate the asm implementation and write C headers that include the asm implementation for both sdcc and sccz80. But it's a lot of work. So I think the underscore thing is eventually on the way out but it's not dead yet. Is anyone looking at sdcc compatibility with the existing library yet?



------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/ ... stg.clktrk
pscust
Well known member
Posts: 194
Joined: Thu Jun 23, 2011 3:34 pm

Post by pscust »

-forcexlib is gone.
I've removed it both from z80asm and zcc.

As for -sdcc, one intermediate step might be the creation of aliases, e.g.

public _anyfunc
defc _anyfunc = anyfunc

Any comments?


On Mon, Feb 23, 2015 at 5:02 AM, alvin (alvin_albrecht@...) <
lists@...> wrote:
> I noticed that zcc still has referenced to the -sdcc and -forcexlib
options. Are these still necessary?

> -forcexlib is a no-op now and should be removed, as the module name is
no longer used as the symbol to force the link of a library module.

well we can probably remove that then.

> -sdcc is forcing z80asm to look-up symbols first as written in the asm
file, and then with a leading underscore, i.e. first 'main' and then, if
the first fails, '_main'.

It doesn't have anything to do with accepting non-standard mnemonics like
"xor a,a", etc?

The new clib does not require the extra underscore lookup but making the
existing library compatible via shortcut may. The existing library will
never be replaced, I think, simply because it probably results in smaller
binaries for stdio and at the moment it contains a lot of specialized
libraries that are not available in the new clib.

I'm not sure how successful that shortcut would be since I think there
would still be problems but that idea hasn't gone away yet. I think the
method used in the new clib is the way to go with the existing library too,
namely we separate the asm implementation and write C headers that include
the asm implementation for both sdcc and sccz80. But it's a lot of work.
So I think the underscore thing is eventually on the way out but it's not
dead yet. Is anyone looking at sdcc compatibility with the existing
library yet?




------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE

http://pubads.g.doubleclick.net/gampad/ ... stg.clktrk
pscust
Well known member
Posts: 194
Joined: Thu Jun 23, 2011 3:34 pm

Post by pscust »

-forcexlib is gone.
I've removed it both from z80asm and zcc.

As for -sdcc, one intermediate step might be the creation of aliases, e.g.

public _anyfunc
defc _anyfunc = anyfunc

Any comments?


On Mon, Feb 23, 2015 at 5:02 AM, alvin (alvin_albrecht@...) <
lists@...> wrote:
> I noticed that zcc still has referenced to the -sdcc and -forcexlib
options. Are these still necessary?

> -forcexlib is a no-op now and should be removed, as the module name is
no longer used as the symbol to force the link of a library module.

well we can probably remove that then.

> -sdcc is forcing z80asm to look-up symbols first as written in the asm
file, and then with a leading underscore, i.e. first 'main' and then, if
the first fails, '_main'.

It doesn't have anything to do with accepting non-standard mnemonics like
"xor a,a", etc?

The new clib does not require the extra underscore lookup but making the
existing library compatible via shortcut may. The existing library will
never be replaced, I think, simply because it probably results in smaller
binaries for stdio and at the moment it contains a lot of specialized
libraries that are not available in the new clib.

I'm not sure how successful that shortcut would be since I think there
would still be problems but that idea hasn't gone away yet. I think the
method used in the new clib is the way to go with the existing library too,
namely we separate the asm implementation and write C headers that include
the asm implementation for both sdcc and sccz80. But it's a lot of work.
So I think the underscore thing is eventually on the way out but it's not
dead yet. Is anyone looking at sdcc compatibility with the existing
library yet?




------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE

http://pubads.g.doubleclick.net/gampad/ ... stg.clktrk
Post Reply