Bug 143937
Summary: | ByteCodeParser::m_currentSemanticOrigin is incorrect for multiple setLocals in a single bytecode instruction | ||
---|---|---|---|
Product: | WebKit | Reporter: | Filip Pizlo <fpizlo> |
Component: | JavaScriptCore | Assignee: | Benjamin Poulain <benjamin> |
Status: | RESOLVED INVALID | ||
Severity: | Normal | ||
Priority: | P2 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | All | ||
OS: | All |
Filip Pizlo
The DFG bytecode parser has a bunch of machinery to handle the possibility that a single bytecode instruction will have multiple SetLocals. At some point we added a m_currentSemanticOrigin thing for making the semantic origin of a SetLocal look "right". But, that functionality assumes that there will be just one SetLocal per bytecode instruction.
We probably don't have bytecode instructions with multiple SetLocals right now, but that is by no means a rule of bytecode.
So, this should either be fixed, or the m_currentSemanticOrigin feature should be removed. There is probably no harm in a SetLocal having the semantic origin of the following instruction.
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Benjamin Poulain
What's the problem with having multiple SetLocal per bytecode?
The semantic origin always follows the local (immediately or stored on DelayedSetLocal). Are you saying there are cases where setLocal() could be re-entrant? How come?
Filip Pizlo
Oh, never mind. I misread the code!