From 962620c90e42a088ed48b1124acddc9b707daca0 Mon Sep 17 00:00:00 2001 From: Mohanson Date: Tue, 5 Mar 2024 19:46:15 +0800 Subject: [PATCH] Rename instance_id => process_id --- script/src/v2_scheduler.rs | 2 +- script/src/v2_syscalls.rs | 18 ++++++++---------- script/src/v2_types.rs | 4 +--- 3 files changed, 10 insertions(+), 14 deletions(-) diff --git a/script/src/v2_scheduler.rs b/script/src/v2_scheduler.rs index 5f768ff99d..aa1bc0d79c 100644 --- a/script/src/v2_scheduler.rs +++ b/script/src/v2_scheduler.rs @@ -328,7 +328,7 @@ impl(&mut self, machine: &mut Mac) -> Result<(), Error> { + fn process_id(&mut self, machine: &mut Mac) -> Result<(), Error> { // TODO: charge cycles machine.set_register(A0, Mac::REG::from_u64(self.id)); Ok(()) @@ -509,7 +507,7 @@ impl< // than currently assigned syscall numbers for spawn calls 2601 => self.spawn(machine), 2602 => self.wait(machine), - 2603 => self.instance_id(machine), + 2603 => self.process_id(machine), 2604 => self.pipe(machine), 2605 => self.pipe_write(machine), 2606 => self.pipe_read(machine), diff --git a/script/src/v2_types.rs b/script/src/v2_types.rs index 1f7967371d..7beb62391f 100644 --- a/script/src/v2_types.rs +++ b/script/src/v2_types.rs @@ -1,5 +1,3 @@ -// Core data structures here - use crate::ScriptGroup; use ckb_traits::{CellDataProvider, ExtensionProvider, HeaderProvider}; use ckb_types::core::{cell::ResolvedTransaction, Cycle}; @@ -69,7 +67,7 @@ pub struct SpawnArgs { pub length: u64, pub argv: Vec, pub pipes: Vec, - pub instance_id_addr: u64, + pub process_id_addr: u64, } #[derive(Clone, Debug)]