Bug 166988
Summary: | Heap uses pointers way too much | ||
---|---|---|---|
Product: | WebKit | Reporter: | Filip Pizlo <fpizlo> |
Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> |
Status: | NEW | ||
Severity: | Normal | CC: | darin, kling |
Priority: | P2 | ||
Version: | WebKit Nightly Build | ||
Hardware: | All | ||
OS: | All | ||
Bug Depends on: | |||
Bug Blocks: | 165909 |
Filip Pizlo
The Heap uses pointers in a lot of places where we would ordinarily use references. In JSC we use references when:
- Not pointing to the JSC heap. (Most of Heap's pointers are not heap pointers.)
- The pointer is immutable.
- Using references would not introduce lots of * to & (and vice-versa) conversions.
- The pointer is non-null.
Under these rules, we could move most of Heap's pointers to references. I think we should do it all at once or in a short burst of patches right next to each other.
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Filip Pizlo
I'm going to use this bug for planting FIXMEs at all of the Heap's undesirable uses of pointers. I don't want to change this code right now because I have bigger fish to fry, but I want a way to track all of the places that bother me.