Branch: refs/heads/main Home: https://github.com/WebKit/WebKit Commit: 82e443e19211b53ce41ef890967bf6a9291806dd https://github.com/WebKit/WebKit/commit/82e443e19211b53ce41ef890967bf6a9291806dd Author: Daniel Liu <danl...@umich.edu> Date: 2024-09-20 (Fri, 20 Sep 2024)
Changed paths: A JSTests/wasm/ipint-tests/ipint-test-implicit-return.js A JSTests/wasm/ipint-tests/ipint-test-simd-i32-params.js M JSTests/wasm/ipint-tests/ipint-test-simd.js M Source/JavaScriptCore/assembler/JITOperationList.cpp M Source/JavaScriptCore/bytecode/BytecodeList.rb M Source/JavaScriptCore/llint/InPlaceInterpreter.asm M Source/JavaScriptCore/llint/InPlaceInterpreter.h M Source/JavaScriptCore/llint/InPlaceInterpreter32_64.asm M Source/JavaScriptCore/llint/InPlaceInterpreter64.asm M Source/JavaScriptCore/llint/LLIntThunks.cpp M Source/JavaScriptCore/llint/LLIntThunks.h M Source/JavaScriptCore/llint/LowLevelInterpreter.asm M Source/JavaScriptCore/wasm/WasmCallee.cpp M Source/JavaScriptCore/wasm/WasmCallee.h M Source/JavaScriptCore/wasm/WasmCallingConvention.h M Source/JavaScriptCore/wasm/WasmFunctionIPIntMetadataGenerator.cpp M Source/JavaScriptCore/wasm/WasmFunctionIPIntMetadataGenerator.h M Source/JavaScriptCore/wasm/WasmIPIntGenerator.cpp M Source/JavaScriptCore/wasm/WasmIPIntGenerator.h M Source/JavaScriptCore/wasm/WasmIPIntPlan.cpp M Source/JavaScriptCore/wasm/WasmIPIntSlowPaths.cpp M Source/JavaScriptCore/wasm/WasmIPIntSlowPaths.h A Tools/lldb/debug_ipint.py Log Message: ----------- Reduce IPInt register usage and support JITless calls https://bugs.webkit.org/show_bug.cgi?id=279934 rdar://136256088 Reviewed by Yusuke Suzuki. This patch performs a signficant cleanup of IPInt code. The key changes: - Introduced a new register assignment for IPInt's internal registers. PC/PB and MC/MB have been condensed to PC and MC, and metadata now stores relative offsets in the bytecode/metadata instead of absolute positions. - Reducing the number of registers used also allows us to significantly clean up calling. - Added support for JITless calls into IPInt. - Removed instances of IPInt writing to metadata in the interpreter, ensuring that metadata is static. - Added LLDB scripting to support debugging IPInt. * JSTests/wasm/ipint-tests/ipint-test-implicit-return.js: Copied from JSTests/wasm/ipint-tests/ipint-test-simd.js. (from.string_appeared_here.import.as.assert.from.string_appeared_here.let.wat.module.func.export.string_appeared_here.result.i32.i32.const.5.async test): * JSTests/wasm/ipint-tests/ipint-test-simd-i32-params.js: Copied from JSTests/wasm/ipint-tests/ipint-test-simd.js. (from.string_appeared_here.import.as.assert.from.string_appeared_here.let.wat.module.func.export.string_appeared_here.param.i32.param.i32.result.i32.v128.const.i32x4.2.3.4.5.i32x4.extract_lane.2.local.0.local.1.i32.div_s.i32.add.return.async test): * JSTests/wasm/ipint-tests/ipint-test-simd.js: (from.string_appeared_here.import.as.assert.from.string_appeared_here.let.wat.module.func.export.string_appeared_here.result.i32.v128.const.i32x4.2.3.4.5.i32x4.extract_lane.0.return.async test): (from.string_appeared_here.import.as.assert.from.string_appeared_here.let.wat.module.func.export.string_appeared_here.result.i32.v128.const.i32x4.0.1.2.3.i32x4.extract_lane.0.return.async test): Deleted. * Source/JavaScriptCore/assembler/JITOperationList.cpp: (JSC::llintOperations): * Source/JavaScriptCore/bytecode/BytecodeList.rb: * Source/JavaScriptCore/llint/InPlaceInterpreter.asm: * Source/JavaScriptCore/llint/InPlaceInterpreter.h: * Source/JavaScriptCore/llint/InPlaceInterpreter64.asm: * Source/JavaScriptCore/llint/LLIntThunks.cpp: (JSC::LLInt::inPlaceInterpreterEntryThunk): (JSC::LLInt::inPlaceInterpreterEntryThunkSIMD): Deleted. * Source/JavaScriptCore/llint/LLIntThunks.h: * Source/JavaScriptCore/wasm/WasmCallee.cpp: (JSC::Wasm::IPIntCallee::IPIntCallee): (JSC::Wasm::JITLessJSEntrypointCallee::JITLessJSEntrypointCallee): * Source/JavaScriptCore/wasm/WasmCallee.h: * Source/JavaScriptCore/wasm/WasmCallingConvention.h: * Source/JavaScriptCore/wasm/WasmFunctionIPIntMetadataGenerator.cpp: (JSC::Wasm::FunctionIPIntMetadataGenerator::addLength): (JSC::Wasm::FunctionIPIntMetadataGenerator::addLEB128ConstantInt32AndLength): (JSC::Wasm::FunctionIPIntMetadataGenerator::addLEB128ConstantAndLengthForType): (JSC::Wasm::FunctionIPIntMetadataGenerator::addLEB128V128Constant): (JSC::Wasm::FunctionIPIntMetadataGenerator::addReturnData): * Source/JavaScriptCore/wasm/WasmFunctionIPIntMetadataGenerator.h: (JSC::Wasm::FunctionIPIntMetadataGenerator::addBlankSpace): (JSC::Wasm::FunctionIPIntMetadataGenerator::appendMetadata): * Source/JavaScriptCore/wasm/WasmIPIntGenerator.cpp: (JSC::Wasm::IPIntGenerator::tryToResolveEntryTarget): (JSC::Wasm::IPIntGenerator::tryToResolveExitTarget): (JSC::Wasm::IPIntGenerator::tryToResolveBranchTarget): (JSC::Wasm::IPIntGenerator::curPC): (JSC::Wasm::IPIntGenerator::nextPC): (JSC::Wasm::IPIntGenerator::curMC): (JSC::Wasm::IPIntGenerator::addConstant): (JSC::Wasm::IPIntGenerator::addTableInit): (JSC::Wasm::IPIntGenerator::addTableGrow): (JSC::Wasm::IPIntGenerator::addTableFill): (JSC::Wasm::IPIntGenerator::addTableCopy): (JSC::Wasm::IPIntGenerator::getGlobal): (JSC::Wasm::IPIntGenerator::setGlobal): (JSC::Wasm::IPIntGenerator::coalesceControlFlow): (JSC::Wasm::IPIntGenerator::resolveEntryTarget): (JSC::Wasm::IPIntGenerator::resolveExitTarget): (JSC::Wasm::IPIntGenerator::addBlock): (JSC::Wasm::IPIntGenerator::addLoop): (JSC::Wasm::IPIntGenerator::addIf): (JSC::Wasm::IPIntGenerator::addElseToUnreachable): (JSC::Wasm::IPIntGenerator::addTry): (JSC::Wasm::IPIntGenerator::addCatchToUnreachable): (JSC::Wasm::IPIntGenerator::addCatchAllToUnreachable): (JSC::Wasm::IPIntGenerator::addDelegateToUnreachable): (JSC::Wasm::IPIntGenerator::addThrow): (JSC::Wasm::IPIntGenerator::addRethrow): (JSC::Wasm::IPIntGenerator::addBranch): (JSC::Wasm::IPIntGenerator::addSwitch): (JSC::Wasm::IPIntGenerator::addEndToUnreachable): (JSC::Wasm::fprToIndex): (JSC::Wasm::IPIntGenerator::addCallCommonData): (JSC::Wasm::IPIntGenerator::addCall): (JSC::Wasm::IPIntGenerator::addCallIndirect): (JSC::Wasm::IPIntGenerator::condenseControlFlowInstructions): Deleted. * Source/JavaScriptCore/wasm/WasmIPIntGenerator.h: * Source/JavaScriptCore/wasm/WasmIPIntPlan.cpp: (JSC::Wasm::IPIntPlan::compileFunction): (JSC::Wasm::IPIntPlan::ensureEntrypoint): (JSC::Wasm::IPIntPlan::didCompleteCompilation): * Source/JavaScriptCore/wasm/WasmIPIntSlowPaths.cpp: (JSC::IPInt::WASM_IPINT_EXTERN_CPP_DECL): (JSC::IPInt::doWasmCall): * Source/JavaScriptCore/wasm/WasmIPIntSlowPaths.h: * Tools/lldb/debug_ipint.py: Added. (print_value): (print_stack): (ipint_state): (ipint_stack): (ipint_local): (ipint_continue_until): (ipint_break_at): (ipint_disable_all_breakpoints): (ipint_reenable_all_breakpoints): (set_breakpoints): (__lldb_init_module): Canonical link: https://commits.webkit.org/284022@main To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications _______________________________________________ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes