Changeset 223919 in webkit for trunk/Source/JavaScriptCore/ftl/FTLLowerDFGToB3.cpp
- Timestamp:
- Oct 24, 2017, 1:48:03 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ftl/FTLLowerDFGToB3.cpp
r223738 r223919 801 801 compileNewObject(); 802 802 break; 803 case NewStringObject: 804 compileNewStringObject(); 805 break; 803 806 case NewArray: 804 807 compileNewArray(); … … 4903 4906 setJSValue(allocateObject(m_node->structure())); 4904 4907 mutatorFence(); 4908 } 4909 4910 void compileNewStringObject() 4911 { 4912 RegisteredStructure structure = m_node->structure(); 4913 LValue string = lowString(m_node->child1()); 4914 4915 LBasicBlock slowCase = m_out.newBlock(); 4916 LBasicBlock continuation = m_out.newBlock(); 4917 4918 LBasicBlock lastNext = m_out.insertNewBlocksBefore(slowCase); 4919 4920 LValue fastResultValue = allocateObject<StringObject>(structure, m_out.intPtrZero, slowCase); 4921 m_out.storePtr(m_out.constIntPtr(StringObject::info()), fastResultValue, m_heaps.JSDestructibleObject_classInfo); 4922 m_out.store64(string, fastResultValue, m_heaps.JSWrapperObject_internalValue); 4923 mutatorFence(); 4924 ValueFromBlock fastResult = m_out.anchor(fastResultValue); 4925 m_out.jump(continuation); 4926 4927 m_out.appendTo(slowCase, continuation); 4928 VM& vm = this->vm(); 4929 LValue slowResultValue = lazySlowPath( 4930 [=, &vm] (const Vector<Location>& locations) -> RefPtr<LazySlowPath::Generator> { 4931 return createLazyCallGenerator(vm, 4932 operationNewStringObject, locations[0].directGPR(), locations[1].directGPR(), 4933 CCallHelpers::TrustedImmPtr(structure.get())); 4934 }, 4935 string); 4936 ValueFromBlock slowResult = m_out.anchor(slowResultValue); 4937 m_out.jump(continuation); 4938 4939 m_out.appendTo(continuation, lastNext); 4940 setJSValue(m_out.phi(pointerType(), fastResult, slowResult)); 4905 4941 } 4906 4942
Note:
See TracChangeset
for help on using the changeset viewer.