removing virtual function assembler code
18 Jul 2000 12:58:59 -0400

          From comp.compilers

Related articles
removing virtual function assembler code (2000-07-18)
| List of all articles for this month |

Newsgroups: comp.compilers
Date: 18 Jul 2000 12:58:59 -0400
Organization: - Before you buy.
Keywords: question, C++

I wonder if there is any way of minimizing the assembled code using

We have a C++ application running on a 68360 and we want to minimize
the memory usage in all possible ways.

And I noticed that there are a lot for function defintions in the
assembled code that takes a lot of memory.

These functions do not do any useful as can be seen from the code
below, but I understand that they are generated as they are needed,
but in this case I wonder, can calls to theses method not be removed
at compilation time as they do not do anything?

Or can the link, ulnk instructions be removed to atleast minimize the

.globl _initB__11SupervisorB
link a6,#0
unlk a6
.globl _initA__11SupervisorB
link a6,#0
unlk a6
link a6,#0
unlk a6
[These look to me like code expanded from a template, where it happens
that the argument is ignored so the code is all the same. Depending
on your linker, it should be possible to collapse these identical routines
together. Or failing that, it should be easy enough to write a perl
script that looks for known patterns and collapses them together. -John]

Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.