home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / sys / next / programm / 6080 < prev    next >
Encoding:
Internet Message Format  |  1992-09-09  |  1.1 KB

  1. Path: sparky!uunet!gatech!darwin.sura.net!ukma!psuvax1!psuvm!mkk2
  2. Organization: Penn State University
  3. Date: Wed, 9 Sep 1992 15:28:36 EDT
  4. From: <MKK2@psuvm.psu.edu>
  5. Message-ID: <92253.152836MKK2@psuvm.psu.edu>
  6. Newsgroups: comp.sys.next.programmer
  7. Subject: Re: Object size and limits
  8. References:  <28935@sophia.inria.fr>
  9. Lines: 20
  10.  
  11.  
  12. In article <28935@sophia.inria.fr>, kjartan@kurosawa.cica.fr (Kjartan Emilsson)
  13. says:
  14.  
  15. >How can you estimate the memory usage of an instance of an object in a
  16. >program, beside using NXWriteObject and looking at the file size ? Is it
  17. >the size of the declared instance variables plus method selectors, or are
  18. >there some additional headers ? Are there any limits to the number of
  19.  
  20. As I understand it, instances are essentially structs, so sizeof
  21. tells you pretty much what you want to know.  Yes, the code for
  22. the methods and the selector tables require some overhead, but they
  23. are not duplicated for each instance.
  24.  
  25. >I'm thinking of order of magnitudes like about 5000 instances of 500+
  26. >classes/categories.
  27.  
  28. If you feel comfortable that your design really needs 500 classes, I don't
  29. forsee any bottleneck.  5000 instances should be no problem.
  30.  
  31.