Bug 160755

Summary: DFG's flushForTerminal() needs to add PhantomLocals for bytecode live locals.
Product: WebKit Reporter: Mark Lam <mark.lam>
Component: JavaScriptCoreAssignee: Mark Lam <mark.lam>
Severity: Normal CC: benjamin, fpizlo, ggaren, keith_miller, msaboff, saam, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Local Build   
Hardware: Unspecified   
OS: Unspecified   
Description Flags
proposed patch. fpizlo: review+

Description Mark Lam 2016-08-10 15:12:02 PDT
If the DFG sees that an inlined function will result in an OSR exit every time, it will treat all downstream blocks as dead.  However, it still needs to keep locals that are alive in the bytecode alive for the compiled function so that those locals are properly written to the stack by the OSR exit ramp.  The existing code neglected to do this.  Will fix.
Comment 1 Mark Lam 2016-08-10 15:12:57 PDT
Comment 2 Mark Lam 2016-08-10 15:22:09 PDT
Created attachment 285770 [details]
proposed patch.
Comment 3 Filip Pizlo 2016-08-10 15:24:10 PDT
Comment on attachment 285770 [details]
proposed patch.

Comment 4 Mark Lam 2016-08-10 16:22:09 PDT
Thanks for the review.  Landed in r204360: <http://trac.webkit.org/r204360>.