Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add implementation of IPInt memory and global instructions
https://bugs.webkit.org/show_bug.cgi?id=259460 rdar://112802752 Reviewed by Justin Michaud. Adds in implementations for (i32|i64|f32|f64).(load|store) instructions (including for smaller sizes), and global.get / global.set. * JSTests/wasm/ipint-tests/ipint-test-global.js: Added. * JSTests/wasm/ipint-tests/ipint-test-memory-read-sizes.js: Added. (from.string_appeared_here.import.as.assert.from.string_appeared_here.let.wat.module.memory.export.string_appeared_here.1.10.func.export.string_appeared_here.result.i32.i32.const.0.i32.load.func.export.string_appeared_here.result.i32.i32.const.0.i32.load8_s.func.export.string_appeared_here.result.i32.i32.const.0.i32.load8_u.func.export.string_appeared_here.result.i32.i32.const.0.i32.load16_s.func.export.string_appeared_here.result.i32.i32.const.0.i32.load16_u.func.export.string_appeared_here.result.i64.i32.const.0.i64.load.func.export.string_appeared_here.result.i64.i32.const.0.i64.load8_s.func.export.string_appeared_here.result.i64.i32.const.0.i64.load8_u.func.export.string_appeared_here.result.i64.i32.const.0.i64.load16_s.func.export.string_appeared_here.result.i64.i32.const.0.i64.load16_u.func.export.string_appeared_here.result.i64.i32.const.0.i64.load32_s.func.export.string_appeared_here.result.i64.i32.const.0.i64.load32_u.writeToMemory): (async test): * JSTests/wasm/ipint-tests/ipint-test-memory-read.js: Added. (from.string_appeared_here.import.as.assert.from.string_appeared_here.let.wat.module.memory.export.string_appeared_here.1.10.data.i32.const.0x0.string_appeared_here.func.export.string_appeared_here.param.i32.result.i32.local.0.i32.load8_u.return.writeStringToMemory): (async test): * JSTests/wasm/ipint-tests/ipint-test-memory-simple.js: Added. (from.string_appeared_here.import.as.assert.from.string_appeared_here.let.wat.module.memory.export.string_appeared_here.1.10.data.i32.const.0x0.string_appeared_here.func.export.string_appeared_here.i32.const.0.i32.const.1717661556.i32.store.i32.const.4.i32.const.117.i32.store.decodeString): (async test): * JSTests/wasm/ipint-tests/ipint-test-memory-write-sizes.js: Added. (from.string_appeared_here.import.as.assert.from.string_appeared_here.let.wat.module.memory.export.string_appeared_here.1.10.func.export.string_appeared_here.param.i32.i32.local.0.local.1.i32.store.func.export.string_appeared_here.param.i32.i32.local.0.local.1.i32.store8.func.export.string_appeared_here.param.i32.i32.local.0.local.1.i32.store16.func.export.string_appeared_here.param.i32.i64.local.0.local.1.i64.store.func.export.string_appeared_here.param.i32.i64.local.0.local.1.i64.store8.func.export.string_appeared_here.param.i32.i64.local.0.local.1.i64.store16.func.export.string_appeared_here.param.i32.i64.local.0.local.1.i64.store32.decodeString): (async test): * Source/JavaScriptCore/llint/InPlaceInterpreter.asm: * Source/JavaScriptCore/wasm/WasmFunctionIPIntMetadataGenerator.cpp: (JSC::Wasm::FunctionIPIntMetadataGenerator::addLEB128ConstantInt32AndLength): (JSC::Wasm::sizeOfLEB128): Deleted. * Source/JavaScriptCore/wasm/WasmIPIntGenerator.cpp: (JSC::Wasm::IPIntGenerator::getLocal): (JSC::Wasm::IPIntGenerator::setLocal): (JSC::Wasm::IPIntGenerator::getGlobal): (JSC::Wasm::IPIntGenerator::setGlobal): (JSC::Wasm::IPIntGenerator::load): (JSC::Wasm::IPIntGenerator::store): * Source/JavaScriptCore/wasm/WasmSlowPaths.cpp: (JSC::LLInt::doWasmIPIntCallIndirect): (JSC::LLInt::ipintGetGlobal64B): (JSC::LLInt::ipintSetGlobal64B): * Source/JavaScriptCore/wasm/WasmSlowPaths.h: Canonical link: https://commits.webkit.org/266306@main
- Loading branch information