Commit c73adafc authored by fpizlo@apple.com's avatar fpizlo@apple.com

DFG OSR exit code should be generated by a separate compiler, not

related to DFG::JITCompiler
https://bugs.webkit.org/show_bug.cgi?id=71787

Reviewed by Gavin Barraclough.
        
Moves the exitSpeculativeWithOSR() method from JITCompiler to
OSRExitCompiler::compileExit().

* CMakeListsEfl.txt:
* JavaScriptCore.xcodeproj/project.pbxproj:
* Target.pri:
* dfg/DFGJITCompiler.cpp:
(JSC::DFG::JITCompiler::linkOSRExits):
* dfg/DFGJITCompiler32_64.cpp: Removed.
* dfg/DFGOSRExitCompiler.h: Added.
(JSC::DFG::OSRExitCompiler::OSRExitCompiler):
* dfg/DFGOSRExitCompiler32_64.cpp: Added.
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGOSRExitCompiler64.cpp: Added.
(JSC::DFG::OSRExitCompiler::compileExit):
* runtime/JSValue.h:



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@99629 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 7266e63b
......@@ -31,9 +31,9 @@ LIST(APPEND JavaScriptCore_SOURCES
dfg/DFGJITCodeGenerator.cpp
dfg/DFGJITCodeGenerator32_64.cpp
dfg/DFGJITCompiler.cpp
dfg/DFGJITCompiler32_64.cpp
dfg/DFGOperations.cpp
dfg/DFGOSREntry.cpp
dfg/DFGOSRExitCompiler32_64.cpp
dfg/DFGPropagator.cpp
dfg/DFGRepatch.cpp
dfg/DFGSpeculativeJIT.cpp
......
2011-11-08 Filip Pizlo <fpizlo@apple.com>
DFG OSR exit code should be generated by a separate compiler, not
related to DFG::JITCompiler
https://bugs.webkit.org/show_bug.cgi?id=71787
Reviewed by Gavin Barraclough.
Moves the exitSpeculativeWithOSR() method from JITCompiler to
OSRExitCompiler::compileExit().
* CMakeListsEfl.txt:
* JavaScriptCore.xcodeproj/project.pbxproj:
* Target.pri:
* dfg/DFGJITCompiler.cpp:
(JSC::DFG::JITCompiler::linkOSRExits):
* dfg/DFGJITCompiler32_64.cpp: Removed.
* dfg/DFGOSRExitCompiler.h: Added.
(JSC::DFG::OSRExitCompiler::OSRExitCompiler):
* dfg/DFGOSRExitCompiler32_64.cpp: Added.
(JSC::DFG::OSRExitCompiler::compileExit):
* dfg/DFGOSRExitCompiler64.cpp: Added.
(JSC::DFG::OSRExitCompiler::compileExit):
* runtime/JSValue.h:
2011-11-08 Filip Pizlo <fpizlo@apple.com>
Basic DFG definitions should be moved out of DFGNode.h
......@@ -71,6 +71,9 @@
0FC0976A1468A6F700CF2442 /* DFGOSRExit.h in Headers */ = {isa = PBXBuildFile; fileRef = 0FC097681468A6EF00CF2442 /* DFGOSRExit.h */; settings = {ATTRIBUTES = (Private, ); }; };
0FC0976D1468AB4E00CF2442 /* DFGAssemblyHelpers.h in Headers */ = {isa = PBXBuildFile; fileRef = 0FC0976C1468AB4A00CF2442 /* DFGAssemblyHelpers.h */; settings = {ATTRIBUTES = (Private, ); }; };
0FC0976E1468AB5100CF2442 /* DFGAssemblyHelpers.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0FC0976B1468AB4A00CF2442 /* DFGAssemblyHelpers.cpp */; };
0FC0977114693AF500CF2442 /* DFGOSRExitCompiler.h in Headers */ = {isa = PBXBuildFile; fileRef = 0FC0976F14693AEF00CF2442 /* DFGOSRExitCompiler.h */; settings = {ATTRIBUTES = (Private, ); }; };
0FC0977214693AF900CF2442 /* DFGOSRExitCompiler64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0FC0977014693AEF00CF2442 /* DFGOSRExitCompiler64.cpp */; };
0FC09776146943B000CF2442 /* DFGOSRExitCompiler32_64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0FC09775146943AD00CF2442 /* DFGOSRExitCompiler32_64.cpp */; };
0FC8150A14043BF500CFA603 /* WriteBarrierSupport.h in Headers */ = {isa = PBXBuildFile; fileRef = 0FC8150914043BD200CFA603 /* WriteBarrierSupport.h */; settings = {ATTRIBUTES = (Private, ); }; };
0FC8150B14043C0E00CFA603 /* WriteBarrierSupport.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0FC8150814043BCA00CFA603 /* WriteBarrierSupport.cpp */; };
0FC815151405119B00CFA603 /* VTableSpectrum.h in Headers */ = {isa = PBXBuildFile; fileRef = 0FC815141405118D00CFA603 /* VTableSpectrum.h */; settings = {ATTRIBUTES = (Private, ); }; };
......@@ -318,7 +321,6 @@
86704B8912DBA33700A9FE7B /* YarrPattern.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 86704B8212DBA33700A9FE7B /* YarrPattern.cpp */; };
86704B8A12DBA33700A9FE7B /* YarrPattern.h in Headers */ = {isa = PBXBuildFile; fileRef = 86704B8312DBA33700A9FE7B /* YarrPattern.h */; settings = {ATTRIBUTES = (Private, ); }; };
86880F1C14328BB900B08D42 /* DFGJITCodeGenerator32_64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 86880F1814328BB900B08D42 /* DFGJITCodeGenerator32_64.cpp */; };
86880F1D14328BB900B08D42 /* DFGJITCompiler32_64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 86880F1914328BB900B08D42 /* DFGJITCompiler32_64.cpp */; };
86880F1E14328BB900B08D42 /* DFGJITCompilerInlineMethods.h in Headers */ = {isa = PBXBuildFile; fileRef = 86880F1A14328BB900B08D42 /* DFGJITCompilerInlineMethods.h */; };
86880F1F14328BB900B08D42 /* DFGSpeculativeJIT32_64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 86880F1B14328BB900B08D42 /* DFGSpeculativeJIT32_64.cpp */; };
86880F44143531A800B08D42 /* DFGJITCodeGenerator64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 86880F43143531A700B08D42 /* DFGJITCodeGenerator64.cpp */; };
......@@ -839,6 +841,9 @@
0FC097681468A6EF00CF2442 /* DFGOSRExit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGOSRExit.h; path = dfg/DFGOSRExit.h; sourceTree = "<group>"; };
0FC0976B1468AB4A00CF2442 /* DFGAssemblyHelpers.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGAssemblyHelpers.cpp; path = dfg/DFGAssemblyHelpers.cpp; sourceTree = "<group>"; };
0FC0976C1468AB4A00CF2442 /* DFGAssemblyHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGAssemblyHelpers.h; path = dfg/DFGAssemblyHelpers.h; sourceTree = "<group>"; };
0FC0976F14693AEF00CF2442 /* DFGOSRExitCompiler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGOSRExitCompiler.h; path = dfg/DFGOSRExitCompiler.h; sourceTree = "<group>"; };
0FC0977014693AEF00CF2442 /* DFGOSRExitCompiler64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGOSRExitCompiler64.cpp; path = dfg/DFGOSRExitCompiler64.cpp; sourceTree = "<group>"; };
0FC09775146943AD00CF2442 /* DFGOSRExitCompiler32_64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGOSRExitCompiler32_64.cpp; path = dfg/DFGOSRExitCompiler32_64.cpp; sourceTree = "<group>"; };
0FC0977E1469EBC400CF2442 /* DFGCommon.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGCommon.h; path = dfg/DFGCommon.h; sourceTree = "<group>"; };
0FC8150814043BCA00CFA603 /* WriteBarrierSupport.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WriteBarrierSupport.cpp; sourceTree = "<group>"; };
0FC8150914043BD200CFA603 /* WriteBarrierSupport.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WriteBarrierSupport.h; sourceTree = "<group>"; };
......@@ -1101,7 +1106,6 @@
867FC35F11B763950025105E /* JavaScriptCore.JSVALUE32_64only.exp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.exports; path = JavaScriptCore.JSVALUE32_64only.exp; sourceTree = "<group>"; };
867FC36111B763950025105E /* JavaScriptCore.JSVALUE64only.exp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.exports; path = JavaScriptCore.JSVALUE64only.exp; sourceTree = "<group>"; };
86880F1814328BB900B08D42 /* DFGJITCodeGenerator32_64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGJITCodeGenerator32_64.cpp; path = dfg/DFGJITCodeGenerator32_64.cpp; sourceTree = "<group>"; };
86880F1914328BB900B08D42 /* DFGJITCompiler32_64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGJITCompiler32_64.cpp; path = dfg/DFGJITCompiler32_64.cpp; sourceTree = "<group>"; };
86880F1A14328BB900B08D42 /* DFGJITCompilerInlineMethods.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGJITCompilerInlineMethods.h; path = dfg/DFGJITCompilerInlineMethods.h; sourceTree = "<group>"; };
86880F1B14328BB900B08D42 /* DFGSpeculativeJIT32_64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGSpeculativeJIT32_64.cpp; path = dfg/DFGSpeculativeJIT32_64.cpp; sourceTree = "<group>"; };
86880F43143531A700B08D42 /* DFGJITCodeGenerator64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGJITCodeGenerator64.cpp; path = dfg/DFGJITCodeGenerator64.cpp; sourceTree = "<group>"; };
......@@ -2299,6 +2303,9 @@
86EC9DB31328DF44002B2AD7 /* dfg */ = {
isa = PBXGroup;
children = (
0FC09775146943AD00CF2442 /* DFGOSRExitCompiler32_64.cpp */,
0FC0976F14693AEF00CF2442 /* DFGOSRExitCompiler.h */,
0FC0977014693AEF00CF2442 /* DFGOSRExitCompiler64.cpp */,
0FC0977E1469EBC400CF2442 /* DFGCommon.h */,
0FC0976B1468AB4A00CF2442 /* DFGAssemblyHelpers.cpp */,
0FC0976C1468AB4A00CF2442 /* DFGAssemblyHelpers.h */,
......@@ -2328,7 +2335,6 @@
86880F43143531A700B08D42 /* DFGJITCodeGenerator64.cpp */,
86EC9DBB1328DF82002B2AD7 /* DFGJITCompiler.cpp */,
86EC9DBC1328DF82002B2AD7 /* DFGJITCompiler.h */,
86880F1914328BB900B08D42 /* DFGJITCompiler32_64.cpp */,
86880F1A14328BB900B08D42 /* DFGJITCompilerInlineMethods.h */,
86ECA3E9132DEF1C002B2AD7 /* DFGNode.h */,
0FD82E52141DAEDE00179C94 /* DFGOSREntry.cpp */,
......@@ -2914,6 +2920,7 @@
0F2E5BF7146357D5003EB2EB /* Spectrum.h in Headers */,
0FC0976A1468A6F700CF2442 /* DFGOSRExit.h in Headers */,
0FC0976D1468AB4E00CF2442 /* DFGAssemblyHelpers.h in Headers */,
0FC0977114693AF500CF2442 /* DFGOSRExitCompiler.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......@@ -3438,7 +3445,6 @@
A70456B11427FB950037DA68 /* AllocationSpace.cpp in Sources */,
86FA9E91142BBB2E001773B7 /* JSBoundFunction.cpp in Sources */,
86880F1C14328BB900B08D42 /* DFGJITCodeGenerator32_64.cpp in Sources */,
86880F1D14328BB900B08D42 /* DFGJITCompiler32_64.cpp in Sources */,
86880F1F14328BB900B08D42 /* DFGSpeculativeJIT32_64.cpp in Sources */,
86880F44143531A800B08D42 /* DFGJITCodeGenerator64.cpp in Sources */,
86880F4D14353B2100B08D42 /* DFGSpeculativeJIT64.cpp in Sources */,
......@@ -3446,6 +3452,8 @@
0F620179143FCD480068B77C /* DFGAbstractState.cpp in Sources */,
BC3C4CA01458F5450025FB62 /* JSGlobalThis.cpp in Sources */,
0FC0976E1468AB5100CF2442 /* DFGAssemblyHelpers.cpp in Sources */,
0FC0977214693AF900CF2442 /* DFGOSRExitCompiler64.cpp in Sources */,
0FC09776146943B000CF2442 /* DFGOSRExitCompiler32_64.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......
......@@ -92,9 +92,10 @@ SOURCES += \
dfg/DFGJITCodeGenerator32_64.cpp \
dfg/DFGJITCodeGenerator64.cpp \
dfg/DFGJITCompiler.cpp \
dfg/DFGJITCompiler32_64.cpp \
dfg/DFGOperations.cpp \
dfg/DFGOSREntry.cpp \
dfg/DFGOSRExitCompiler64.cpp \
dfg/DFGOSRExitCompiler32_64.cpp \
dfg/DFGPropagator.cpp \
dfg/DFGRepatch.cpp \
dfg/DFGSpeculativeJIT.cpp \
......
/*
* Copyright (C) 2011 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef DFGOSRExitCompiler_h
#define DFGOSRExitCompiler_h
#include <wtf/Platform.h>
#if ENABLE(DFG_JIT)
#include "DFGAssemblyHelpers.h"
#include "DFGOSRExit.h"
namespace JSC { namespace DFG {
class OSRExitCompiler {
public:
OSRExitCompiler(AssemblyHelpers& jit)
: m_jit(jit)
{
}
void compileExit(const OSRExit&, SpeculationRecovery*);
private:
AssemblyHelpers& m_jit;
};
} } // namespace JSC::DFG
#endif // ENABLE(DFG_JIT)
#endif // DFGOSRExitCompiler_h
This diff is collapsed.
......@@ -51,6 +51,7 @@ namespace JSC {
class JITCompiler;
class JITCodeGenerator;
class JSValueSource;
class OSRExitCompiler;
class SpeculativeJIT;
}
#endif
......@@ -114,6 +115,7 @@ namespace JSC {
friend class DFG::JITCompiler;
friend class DFG::JITCodeGenerator;
friend class DFG::JSValueSource;
friend class DFG::OSRExitCompiler;
friend class DFG::SpeculativeJIT;
#endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment