The Following User Says Thank You to nwerneck For This Useful Post: | ||
|
2011-02-10
, 22:11
|
Posts: 726 |
Thanked: 345 times |
Joined on Apr 2010
@ Sweden
|
#152
|
This is the out-of-thin-air generalization that makes makes even your good points look bad. D has pointers. C# has pointers. Hell, even Google's brand spanking new Go language has pointers.
The Following User Says Thank You to Joorin For This Useful Post: | ||
|
2011-02-11
, 09:45
|
Posts: 376 |
Thanked: 511 times |
Joined on Aug 2009
@ Greece
|
#153
|
The problem is obvious for me, but I know I should prove it with memory prints comparing the same session and tabs and pages after fresh start and after few days of surfing. Also I could show how cache misses will increase over time with Firefox. I've actually sometimes done these observations but not in a scientific way yet.
|
2011-02-11
, 16:35
|
Posts: 1,341 |
Thanked: 708 times |
Joined on Feb 2010
|
#154
|
|
2011-02-12
, 18:36
|
Posts: 3,319 |
Thanked: 5,610 times |
Joined on Aug 2008
@ Finland
|
#155
|
Just to add a tiny nuance: C# offers pointers if you agree to be on your own, taking full responsibility for it all.
When I have time, I try to prove that slowing down of my Firefox is due to heap memory fragmentation.
No *malloc can remove fragmentation totally, because alive objects cannot be moved in the heap if pointers are allowed in the code (C/C++).
I could point to some studies done for GC+memory management, but you guys can find them yourselves also with google.
|
2011-02-12
, 18:52
|
Posts: 726 |
Thanked: 345 times |
Joined on Apr 2010
@ Sweden
|
#156
|
In what way is that different from C++ ? Admittedly the 'usual C++ way' is heavy with pointer use, but that's not a requirement by any means.
Foo* foo = new Foo();
unsafe { Foo *foo = &someFoo; }
The Following User Says Thank You to Joorin For This Useful Post: | ||
|
2011-02-12
, 21:58
|
Posts: 3,319 |
Thanked: 5,610 times |
Joined on Aug 2008
@ Finland
|
#157
|
|
2011-02-12
, 23:57
|
Posts: 726 |
Thanked: 345 times |
Joined on Apr 2010
@ Sweden
|
#158
|
Yes, I understand that, but IMO that's more syntactic sugar/policy question than a technical differentiation.
The choice is still yours, it's just that you have less 'are you sure' dialogs
The Following User Says Thank You to Joorin For This Useful Post: | ||
|
2011-02-27
, 13:32
|
|
Posts: 3,524 |
Thanked: 2,958 times |
Joined on Oct 2007
@ Delta Quadrant
|
#159
|
The Following User Says Thank You to Capt'n Corrupt For This Useful Post: | ||
|
2011-02-27
, 20:03
|
Posts: 3,319 |
Thanked: 5,610 times |
Joined on Aug 2008
@ Finland
|
#160
|
Huh? If there is something it isn't, it's syntactical sugar.
By declaring an unsafe context/scope you bypass the strict typing checks (not totally, but almost) and if you use fixed pointers you bypass the GC, not letting it move the pointed at memory.
Wouldn't it be possible to create a object/class that emulates pointer memory modification in a safe way?
It could potentially use the array primitive as the heap object to avoid the costly method call per pointer op and provide the mechanisms to do basic [pointer] arithmetic. It could also contain handy functionality to automatically re-size the object as memory needs increase/decrease to more closely emulate C's malloc.
The Following 3 Users Say Thank You to attila77 For This Useful Post: | ||
Tags |
bada rox, dalvik, future, java haters, meego, meego?fail, nokia, sandbox sucks |
|
But I am really replying just to share this quote here with you guys: