ClosureCallStubRoutine no longer needs codeOrigin
authorfpizlo@apple.com <fpizlo@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 20 Jan 2015 05:01:26 +0000 (05:01 +0000)
committerfpizlo@apple.com <fpizlo@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 20 Jan 2015 05:01:26 +0000 (05:01 +0000)
commit35fa6e1779cfcce9edcc943c462590750144adaf
treeb0c1dc18d91f2002aa5e50b7614f85286b485dce
parent9fbac4bd1908133ee7e95dbd5f6350faaa9d4d9c
ClosureCallStubRoutine no longer needs codeOrigin
https://bugs.webkit.org/show_bug.cgi?id=140659

Reviewed by Michael Saboff.

Once upon a time, we would look for the CodeOrigin associated with a return PC. This search
would start with the CodeBlock according to the caller frame's call frame header. But if the
call was a closure call, the return PC would be inside some closure call stub. So if the
CodeBlock search failed, we would search *all* closure call stub routines to see which one
encompasses the return PC. Then, we would use the CodeOrigin stored in the stub routine
object. This was all a bunch of madness, and we actually got rid of it - we now determine
the CodeOrigin for a call frame using the encoded code origin bits inside the tag of the
argument count.

This patch removes the final vestiges of the madness:

- Remove the totally unused method declaration for the thing that did the closure call stub
  search.

- Remove the CodeOrigin field from the ClosureCallStubRoutine. Except for that crazy search
  that we no longer do, everyone else who finds a ClosureCallStubRoutine will find it via
  the CallLinkInfo. The CallLinkInfo also has the CodeOrigin, so we don't need this field
  anymore.

* bytecode/CodeBlock.h:
* jit/ClosureCallStubRoutine.cpp:
(JSC::ClosureCallStubRoutine::ClosureCallStubRoutine):
* jit/ClosureCallStubRoutine.h:
(JSC::ClosureCallStubRoutine::executable):
(JSC::ClosureCallStubRoutine::codeOrigin): Deleted.
* jit/Repatch.cpp:
(JSC::linkClosureCall):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@178693 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/bytecode/CodeBlock.h
Source/JavaScriptCore/jit/ClosureCallStubRoutine.cpp
Source/JavaScriptCore/jit/ClosureCallStubRoutine.h
Source/JavaScriptCore/jit/Repatch.cpp