This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 121925 - Bytes Allocated vs. Objects Allocated vs. Total Alloc. Obj.
Summary: Bytes Allocated vs. Objects Allocated vs. Total Alloc. Obj.
Status: NEW
Alias: None
Product: profiler
Classification: Unclassified
Component: Base (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: issues@profiler
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-11-14 17:31 UTC by Alexander Kouznetsov
Modified: 2007-12-11 03:05 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Kouznetsov 2007-11-14 17:31:45 UTC
Product Version: NetBeans IDE 6.0 RC1 (Build 200711140000)
Java: 1.6.0_03; Java HotSpot(TM) Client VM 1.6.0_03-b05
System: Windows XP version 5.1 running on x86; Cp1251; ru_RU (nb)

Currently in Allocation Memory Profiling mode "Objects Allocated" and "Bytes Allocated" columns contain data collected
differently. While "Objects Allocated" shows the total number of allocated objects, "Bytes Allocated" shows bytes only
for so called "tracked" objects (only each 10 object is tracked by default). The similarity of the column names could be
confusing to user as it looks like objects occupy less bytes of memory (1/10 by default).

Moreover, for Liveness Memory Profiling mode the situation is *not* the same. There we have another column (which is
hidden by default) that shows the total number of allocated objects while "Objects Allocated" column shows only tracked
objects.

I believe that we should eliminate this inconsistency. IMO, the best approach is to change the columns in Memory
Allocation results to match Memory Liveness columns, i. e. count only tracked objects in "Objects Allocated" column and
provide one more column to show total number of Allocated Objects.

At least we should change column tooltips to note this difference.

See also issue 92414
Comment 1 Alexander Kouznetsov 2007-11-15 14:47:52 UTC
Another reason to change this is the fact that Memory Results and Allocation Stack Traces pages of Allocation Memory
Snapshot show different values, so I see in Memory Results 440 allocated char[] objects that occupy 2208 bytes of memory
and if I open Allocation Stack Traces I see that only 92 objects are allocated but they still occupy 2208 bytes of
memory. It looks really disappointing.