The MASM Forum

64 bit assembler => UASM Assembler Development => Topic started by: 2B||!2B on May 14, 2020, 01:22:16 PM

Title: Does UASM support COMDAT?
Post by: 2B||!2B on May 14, 2020, 01:22:16 PM
Is it supported? if so, how can i remove unreferenced functions?
Title: Re: Does UASM support COMDAT?
Post by: johnsa on May 15, 2020, 04:26:00 AM
It can generate COMDAT sections yes.
What is not supported yet is an equivalent to /Gy to put each item in it's own COMDAT section to allow a linker to prune redundant content (or handle merging).

Under Windows / MS Link however you should be able to remove unused functions with /OPT:REF
Title: Re: Does UASM support COMDAT?
Post by: 2B||!2B on May 15, 2020, 04:31:07 AM
Thanks for help. I tried that /OPT:REF but it doesn't remove unrefrenced functions of MASM. I think because all functions are combined into a single .obj file.
Is this a feature that can be added in future for UASM?
Title: Re: Does UASM support COMDAT?
Post by: johnsa on May 15, 2020, 10:03:45 PM
It's on my todo-list :)
Title: Re: Does UASM support COMDAT?
Post by: 2B||!2B on May 19, 2020, 10:27:10 AM
Thank you for the great work you are doing on this assembler  :thup: