TEAM-ADA Archives

Team Ada: Ada Programming Language Advocacy

TEAM-ADA@LISTSERV.ACM.ORG

Options: Use Classic View

Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Topic: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Simon Wright <[log in to unmask]>
Fri, 9 Jun 2000 20:21:19 +0100
text/plain (42 lines)
> From: "W. Wesley Groleau x4923" <[log in to unmask]>

> If I remember right, there was a message nearly a year ago stating that
> the Booch Components in Ada were fewer SLOC than those in C++.

I think it was rather more than a year ago (it was David Weller who
said that, and I officially took over the BCs on 18.vii.98).

> Would it be feasible to create C++, Java, C, etc. bindings to the
> Ada Booch Components and "market" that as not merely a cute demo of
> Ada, but a demo that is actually useful?

Cute demo, hah!!! There are people (including myself) using the BCs
where it counts.

I suppose it might be possible to create C++ bindings, but I have to
say that if I were faced with the need for containers in a C++ context
I would choose the STL. Standards rule, even if they're "standards",
and I think the STL is more than that.

C -- well, that might be hard, given that the BCs are entirely based
on generics. [Actually, I guess that does for C++ too - and almost
certainly Java]

> How does the object size, compile time, and execution efficiency
> compare?

I checked this for the Stack tests. I don't suppose that the figures
mean much, but I compared the Ada stack_test and the C++ stackt using
GNAT 3.12a2 and gcc 2.95.1 respectively.

stack_test has some additional tests, while stackt includes tests
using non-primitive types. I don't think there's a lot of difference.

The Ada source comes to 2375 non-blank non-comment lines, executable
(stripped, -O2 -gnatp) 115824 bytes, while the C++ source comes to
2781 lines, executable (stripped, -O2) 111496 bytes. The average
non-white-space characters-per-line was 26 in both cases. I couldn't
see the difference in the execution time (both very short).

Not really compelling, sorry!

ATOM RSS1 RSS2