digitalmars.D.bugs - [Issue 2586] New: broken import gcstats
- d-bugmail puremagic.com (22/22) Jan 15 2009 http://d.puremagic.com/issues/show_bug.cgi?id=2586
- d-bugmail puremagic.com (17/17) Jan 15 2009 http://d.puremagic.com/issues/show_bug.cgi?id=2586
- d-bugmail puremagic.com (22/22) Jan 16 2009 http://d.puremagic.com/issues/show_bug.cgi?id=2586
- d-bugmail puremagic.com (13/13) Jun 10 2011 http://d.puremagic.com/issues/show_bug.cgi?id=2586
http://d.puremagic.com/issues/show_bug.cgi?id=2586 Summary: broken import gcstats Product: D Version: 2.023 Platform: PC OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: bugzilla digitalmars.com ReportedBy: someanon yahoo.com the file is in dmd-v2.023/src/druntime/src/gc/basic/gcstats.d and declared: module gc.gcstats; However, if I do: import gc.gcstats; dmd says: module gcstats cannot read file 'gc/gcstats.d' if I do: import gcstats; dmd says: module gcstats cannot read file 'gcstats.d' So how do I import gcstats? --
Jan 15 2009
http://d.puremagic.com/issues/show_bug.cgi?id=2586 and more fun: previously I call: std.gc.getStats(...); according to: http://digitalmars.com/d/2.0/changelog.html#new2_020 from to std.gc.*() memory.gc_*() I tried: memory.gc_getStats(gs); it says: Error: undefined identifier memory I tried: core.memory.gc_getStats(gs); it says: Error: undefined identifier module memory.gc_getStats I tried: core.memory.gc.getStats(gs); it says: Error: undefined identifier module memory.gc I tried: core.memory.getStats(gs); it says: Error: undefined identifier module memory.getStats Come on!!!!! is the release package really tested? or the doc accurate at all? --
Jan 15 2009
http://d.puremagic.com/issues/show_bug.cgi?id=2586 sean invisibleduck.org changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|bugzilla digitalmars.com |sean invisibleduck.org Since that module isn't in the import directory, it should be clear that it's not intended to be externally visible. GC stats have yet to be formally defined in druntime, so there is no public interface for accessing them. You can obtain them manually via: struct GCStats { size_t poolsize; // total size of pool size_t usedsize; // bytes allocated size_t freeblocks; // number of blocks marked FREE size_t freelistsize; // total of memory on free lists size_t pageblocks; // number of blocks marked PAGE } extern (C) GCStats gc_stats(); auto s = gc_stats(); But be aware that the structure of GCStats may change. --
Jan 16 2009
http://d.puremagic.com/issues/show_bug.cgi?id=2586 yebblies <yebblies gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |yebblies gmail.com Resolution| |FIXED The package.module now matches the directory and file name, so this would work if you added the right directories to the import path. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Jun 10 2011