Closed
Bug 538545
Opened 14 years ago
Closed 14 years ago
Zeroing of strings table in AvmCore::AvmCore probably redundant
Categories
(Tamarin Graveyard :: Virtual Machine, defect)
Tamarin Graveyard
Virtual Machine
Tracking
(Not tracked)
RESOLVED
FIXED
Future
People
(Reporter: lhansen, Assigned: stejohns)
References
Details
(Whiteboard: PACMAN)
Attachments
(1 file)
2.08 KB,
patch
|
lhansen
:
review+
|
Details | Diff | Splinter Review |
The code is this: strings = mmfx_new_array(DRC(Stringp), numStrings); VMPI_memset(strings, 0, numStrings*sizeof(DRC(Stringp))); However, mmfx_new_array runs the constructor for each array element, and the DRC (really RCPtr<T>) constructor sets the memory to zero. Ergo the memset is probably redundant (though it won't be redundant if DRC is a no-op, as it would be if refrerence counting were to be disabled).
Reporter | ||
Comment 1•14 years ago
|
||
Probably DRC() can't ever be a no-op, even if RC is disabled, precisely for this reason.
Whiteboard: PACMAN
Assignee | ||
Comment 2•14 years ago
|
||
Assignee: nobody → stejohns
Attachment #477625 -
Flags: review?(lhansen)
Reporter | ||
Updated•14 years ago
|
Attachment #477625 -
Flags: review?(lhansen) → review+
Assignee | ||
Comment 3•14 years ago
|
||
http://hg.mozilla.org/tamarin-redux/rev/9ea03c79e169
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•