Bug 153456 - [GTK][EFL] FTL with B3 does not build
Summary: [GTK][EFL] FTL with B3 does not build
Status: RESOLVED WORKSFORME
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: Other
Hardware: PC Linux
: P2 Minor
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-01-25 15:22 PST by Michael Catanzaro
Modified: 2016-01-26 03:56 PST (History)
7 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Catanzaro 2016-01-25 15:22:01 PST
Manually change FTL_USES_B3 to 1 in DFGCommon.h. Then:


[201/5346] Building CXX object Source/...criptCore.dir/bytecode/CodeBlock.cpp.o
FAILED: /usr/lib64/ccache/clang++   -DBUILDING_GTK__=1 -DBUILDING_JavaScriptCore -DBUILDING_WITH_CMAKE=1 -DDATA_DIR=\"share\" -DGETTEXT_PACKAGE=\"WebKit2GTK-4.0\" -DHAVE_CONFIG_H=1 -DJavaScriptCore_EXPORTS -DLIBDIR=\"/home/mcatanzaro/src/jhbuild/install/lib\" -DSTATICALLY_LINKED_WITH_WTF -DUSER_AGENT_GTK_MAJOR_VERSION=\"602\" -DUSER_AGENT_GTK_MINOR_VERSION=\"1\" -DWEBKITGTK_API_VERSION_STRING=\"4.0\" -I. -I../../Source/JavaScriptCore -I../../Source/JavaScriptCore/.. -I../../Source/JavaScriptCore/API -I../../Source/JavaScriptCore/ForwardingHeaders -I../../Source/JavaScriptCore/assembler -I../../Source/JavaScriptCore/b3 -I../../Source/JavaScriptCore/b3/air -I../../Source/JavaScriptCore/bindings -I../../Source/JavaScriptCore/builtins -I../../Source/JavaScriptCore/bytecode -I../../Source/JavaScriptCore/bytecompiler -I../../Source/JavaScriptCore/dfg -I../../Source/JavaScriptCore/disassembler -I../../Source/JavaScriptCore/disassembler/udis86 -I../../Source/JavaScriptCore/ftl -I../../Source/JavaScriptCore/heap -I../../Source/JavaScriptCore/debugger -I../../Source/JavaScriptCore/inspector -I../../Source/JavaScriptCore/inspector/agents -I../../Source/JavaScriptCore/inspector/augmentable -I../../Source/JavaScriptCore/inspector/remote -I../../Source/JavaScriptCore/interpreter -I../../Source/JavaScriptCore/jit -I../../Source/JavaScriptCore/llint -I../../Source/JavaScriptCore/llvm -I../../Source/JavaScriptCore/parser -I../../Source/JavaScriptCore/profiler -I../../Source/JavaScriptCore/replay -I../../Source/JavaScriptCore/runtime -I../../Source/JavaScriptCore/tools -I../../Source/JavaScriptCore/wasm -I../../Source/JavaScriptCore/yarr -IDerivedSources -IDerivedSources/ForwardingHeaders -IDerivedSources/JavaScriptCore -IDerivedSources/JavaScriptCore/inspector -I../../Source/WTF -isystem /home/mcatanzaro/src/jhbuild/install/include/glib-2.0 -isystem /home/mcatanzaro/src/jhbuild/install/lib/glib-2.0/include -std=c++11 -fcolor-diagnostics -gsplit-dwarf -Qunused-arguments -g -fPIC   -Wall -Wextra -Wcast-align -Wformat-security -Wmissing-format-attribute -Wpointer-arith -Wundef -Wwrite-strings -Wno-parentheses-equality -MMD -MT Source/JavaScriptCore/CMakeFiles/JavaScriptCore.dir/bytecode/CodeBlock.cpp.o -MF Source/JavaScriptCore/CMakeFiles/JavaScriptCore.dir/bytecode/CodeBlock.cpp.o.d -o Source/JavaScriptCore/CMakeFiles/JavaScriptCore.dir/bytecode/CodeBlock.cpp.o -c ../../Source/JavaScriptCore/bytecode/CodeBlock.cpp
In file included from ../../Source/JavaScriptCore/bytecode/CodeBlock.cpp:79:
In file included from ../../Source/JavaScriptCore/ftl/FTLJITCode.h:35:
../../Source/JavaScriptCore/ftl/FTLOSRExit.h:176:12: error: no member named 'ValueRep' in namespace 'JSC::B3'; did you mean 'DFG::ValueRep'?
    Vector<B3::ValueRep> m_valueReps;
           ^~~~~~~~~~~~
           DFG::ValueRep
../../Source/JavaScriptCore/dfg/DFGNodeType.h:367:565: note: 'DFG::ValueRep' declared here
    JSConstant, DoubleConstant, Int52Constant, Identity, ToThis, CreateThis, GetCallee, GetArgumentCount, GetLocal, SetLocal, PutStack, KillStack, GetStack, MovHint, ZombieHint, ExitOK, Phantom, Check, Upsilon, Phi, Flush, PhantomLocal, LoopHint, ExtractOSREntryLocal, CheckTierUpInLoop, CheckTierUpAndOSREnter, CheckTierUpWithNestedTriggerAndOSREnter, CheckTierUpAtReturn, GetLocalUnlinked, SetArgument, InvalidationPoint, BitAnd, BitOr, BitXor, BitLShift, BitRShift, BitURShift, ValueToInt32, UInt32ToNumber, BooleanToNumber, DoubleAsInt32, DoubleRep, Int52Rep, ValueRep, FiatInt52, ArithAdd, ArithClz32, ArithSub, ArithNegate, ArithMul, ArithIMul, ArithDiv, ArithMod, ArithAbs, ArithMin, ArithMax, ArithFRound, ArithPow, ArithRandom, ArithRound, ArithSqrt, ArithSin, ArithCos, ArithLog, ValueAdd, StrCat, GetByVal, GetMyArgumentByVal, LoadVarargs, ForwardVarargs, PutByValDirect, PutByVal, PutByValAlias, GetById, GetByIdFlush, PutById, PutByIdFlush, PutByIdDirect, PutGetterById, PutSetterById, PutGetterSetterById, PutGetterByVal, PutSetterByVal, CheckStructure, GetExecutable, PutStructure, AllocatePropertyStorage, ReallocatePropertyStorage, GetButterfly, GetButterflyReadOnly, CheckArray, Arrayify, ArrayifyToStructure, GetIndexedPropertyStorage, ConstantStoragePointer, GetGetter, GetSetter, GetByOffset, GetGetterSetterByOffset, MultiGetByOffset, PutByOffset, MultiPutByOffset, GetArrayLength, GetTypedArrayByteOffset, GetScope, SkipScope, GetClosureVar, PutClosureVar, GetGlobalVar, GetGlobalLexicalVariable, PutGlobalVariable, NotifyWrite, VarInjectionWatchpoint, CheckCell, CheckNotEmpty, CheckBadCell, CheckInBounds, CheckIdent, CheckTypeInfoFlags, ArrayPush, ArrayPop, RegExpExec, RegExpTest, StringCharCodeAt, StringCharAt, StringFromCharCode, CompareLess, CompareLessEq, CompareGreater, CompareGreaterEq, CompareEq, CompareStrictEq, Call, Construct, CallVarargs, CallForwardVarargs, ConstructVarargs, ConstructForwardVarargs, TailCallInlinedCaller, TailCallVarargsInlinedCaller, TailCallForwardVarargsInlinedCaller, NewObject, NewArray, NewArrayWithSize, NewArrayBuffer, NewTypedArray, NewRegexp, GetRestLength, CopyRest, PhantomNewObject, PutHint, CheckStructureImmediate, MaterializeNewObject, PhantomNewFunction, PhantomNewGeneratorFunction, PhantomCreateActivation, MaterializeCreateActivation, Breakpoint, ProfileWillCall, ProfileDidCall, OverridesHasInstance, InstanceOf, InstanceOfCustom, IsUndefined, IsBoolean, IsNumber, IsString, IsObject, IsObjectOrNull, IsFunction, TypeOf, LogicalNot, ToPrimitive, ToString, CallStringConstructor, NewStringObject, MakeRope, In, ProfileType, ProfileControlFlow, CreateActivation, CreateDirectArguments, PhantomDirectArguments, CreateScopedArguments, CreateClonedArguments, PhantomClonedArguments, GetFromArguments, PutToArguments, NewFunction, NewArrowFunction, NewGeneratorFunction, Throw, ThrowReferenceError, Jump, Branch, Switch, Return, TailCall, TailCallVarargs, TailCallForwardVarargs, Unreachable, CountExecution, ForceOSRExit, BottomValue, CheckWatchdogTimer, StoreBarrier, GetEnumerableLength, HasIndexedProperty, HasStructureProperty, HasGenericProperty, GetDirectPname, GetPropertyEnumerator, GetEnumeratorStructurePname, GetEnumeratorGenericPname, ToIndexString,
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ^
In file included from ../../Source/JavaScriptCore/bytecode/CodeBlock.cpp:79:
In file included from ../../Source/JavaScriptCore/ftl/FTLJITCode.h:35:
../../Source/JavaScriptCore/ftl/FTLOSRExit.h:176:12: error: template argument for template type parameter must be a type
    Vector<B3::ValueRep> m_valueReps;
           ^~~~~~~~~~~~
../../Source/WTF/wtf/Forward.h:37:19: note: template parameter is declared here
template<typename T, size_t inlineCapacity, typename OverflowHandler, size_t minCapacity> class Vector;
                  ^
In file included from ../../Source/JavaScriptCore/bytecode/CodeBlock.cpp:79:
In file included from ../../Source/JavaScriptCore/ftl/FTLJITCode.h:35:
../../Source/JavaScriptCore/ftl/FTLOSRExit.h:193:22: error: cannot initialize object parameter of type 'JSC::DFG::OSRExitBase' with an expression of type 'JSC::FTL::OSRExit'
        OSRExitBase::considerAddingAsFrequentExitSite(profiledCodeBlock, ExitFromFTL);
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../../Source/JavaScriptCore/bytecode/CodeBlock.cpp:79:
../../Source/JavaScriptCore/ftl/FTLJITCode.h:72:53: error: no member named 'OpaqueByproducts' in namespace 'JSC::B3'
    void initializeB3Byproducts(std::unique_ptr<B3::OpaqueByproducts>);
                                                ~~~~^
../../Source/JavaScriptCore/ftl/FTLJITCode.h:111:25: error: no member named 'OpaqueByproducts' in namespace 'JSC::B3'
    std::unique_ptr<B3::OpaqueByproducts> m_b3Byproducts;
                    ~~~~^
5 errors generated.
[201/5346] Building CXX object Source/...bytecode/LazyOperandValueProfile.cpp.o
ninja: build stopped: subcommand failed.
Comment 1 Gyuyoung Kim 2016-01-25 19:26:12 PST
It looks like EFL port has same build error. This fix may support EFL port as well.
Comment 2 Csaba Osztrogonác 2016-01-26 03:47:51 PST
To enable B3 JIT, you need to 
- set ENABLE_B3_JIT to 1 in Platform.h
- set FTL_USES_B3 to 1 in DFGCommon.h