record Q_entryM: int; // the application messagetag: int; // unique me dịch - record Q_entryM: int; // the application messagetag: int; // unique me Việt làm thế nào để nói

record Q_entryM: int; // the applic

record Q_entry
M: int; // the application message
tag: int; // unique message identifier sender_id: int; // sender of the message timestamp: int; // tentative timestamp assigned to message deliverable: boolean; // whether message is ready for delivery
(local variables)
queue of Q_entry: temp_Q, delivery_Q
int: clock // Used as a variant of Lamport’s scalar clock
int: priority // Used to track the highest proposed timestamp (message types)
REVISE_TS(M, i, tag, ts)
// Phase 1 message sent by Pi, with initial timestamp ts
PROPOSED_TS(j, i, tag, ts)
// Phase 2 message sent by Pj , with revised timestamp, to Pi
FINAL_TS(i, tag, ts) // Phase 3 message sent by Pi, with final timestamp
(1) When process Pi wants to multicast a message M with a tag tag: (1a) clock ← clock + 1;
(1b) send REVISE_TS(M, i, tag, clock) to all processes; (1c) temp_ts ← 0;
(1d) await PROPOSED_TS(j, i, tag, tsj) from each process Pj ; (1e) ∀j ∈ N , do temp_ts ← max(temp_ts, tsj);
(1f) send FINAL_TS(i, tag, temp_ts) to all processes; (1g) clock ← max(clock, temp_ts).
(2) When REVISE_TS(M, j, tag, clk) arrives from Pj : (2a) priority ← max(priority + 1, clk);
(2b) insert (M, tag, j, priority, undeliverable) in temp_Q;
// at end of queue
(2c) send PROPOSED_TS(i, j, tag, priority) to Pj .
(3) When FINAL_TS(j, x, clk) arrives from Pj :
(3a) Identify entry Q_e in temp_Q, where Q_e.tag = x;
(3b) mark Q_e.deliverable as true;
(3c) Update Q_e.timestamp to clk and re-sort temp_Q based on the
timestamp field;
(3d) if (head(temp_Q)).tag = Q_e.tag then
(3e) move Q_e from temp_Q to delivery_Q; (3f) while (head(temp_Q)).deliverable is true do
(3g) dequeue head(temp_Q) and insert in delivery_Q.
(4) When Pi removes a message (M, tag, j, ts, deliverable) from
head(delivery_Qi):
(4a) clock ← max(clock, ts) + 1.
0/5000
Từ: -
Sang: -
Kết quả (Việt) 1: [Sao chép]
Sao chép!
record Q_entryM: int; // the application messagetag: int; // unique message identifier sender_id: int; // sender of the message timestamp: int; // tentative timestamp assigned to message deliverable: boolean; // whether message is ready for delivery(local variables)queue of Q_entry: temp_Q, delivery_Qint: clock // Used as a variant of Lamport’s scalar clockint: priority // Used to track the highest proposed timestamp (message types)REVISE_TS(M, i, tag, ts)// Phase 1 message sent by Pi, with initial timestamp tsPROPOSED_TS(j, i, tag, ts)// Phase 2 message sent by Pj , with revised timestamp, to PiFINAL_TS(i, tag, ts) // Phase 3 message sent by Pi, with final timestamp(1) When process Pi wants to multicast a message M with a tag tag: (1a) clock ← clock + 1;(1b) send REVISE_TS(M, i, tag, clock) to all processes; (1c) temp_ts ← 0;(1d) await PROPOSED_TS(j, i, tag, tsj) from each process Pj ; (1e) ∀j ∈ N , do temp_ts ← max(temp_ts, tsj);(1f) send FINAL_TS(i, tag, temp_ts) to all processes; (1g) clock ← max(clock, temp_ts).(2) When REVISE_TS(M, j, tag, clk) arrives from Pj : (2a) priority ← max(priority + 1, clk);(2b) insert (M, tag, j, priority, undeliverable) in temp_Q;// at end of queue(2c) send PROPOSED_TS(i, j, tag, priority) to Pj .(3) When FINAL_TS(j, x, clk) arrives from Pj :(3a) Identify entry Q_e in temp_Q, where Q_e.tag = x;(3b) mark Q_e.deliverable as true;(3c) Update Q_e.timestamp to clk and re-sort temp_Q based on thetimestamp field;(3d) if (head(temp_Q)).tag = Q_e.tag then(3e) move Q_e from temp_Q to delivery_Q; (3f) while (head(temp_Q)).deliverable is true do(3g) dequeue head(temp_Q) and insert in delivery_Q.(4) When Pi removes a message (M, tag, j, ts, deliverable) fromhead(delivery_Qi):(4a) clock ← max(clock, ts) + 1.
đang được dịch, vui lòng đợi..
Kết quả (Việt) 2:[Sao chép]
Sao chép!
kỷ lục Q_entry
M: int; // Thông điệp ứng dụng
tag: int; // Định danh độc đáo sender_id nhắn: int; // Người gửi tin nhắn timestamp: int; // Dấu thời gian dự kiến giao cho thông điệp chuyển giao: boolean; // Liệu tin nhắn đã sẵn sàng cho giao hàng
(biến cục bộ)
hàng đợi của Q_entry: temp_Q, delivery_Q
int: đồng hồ // Được sử dụng như là một biến thể của vô hướng đồng hồ Lamport của
int: ưu tiên // Được sử dụng để theo dõi các dấu thời gian được đề xuất cao nhất (các loại tin nhắn)
REVISE_TS ( M, i, tag, ts)
// Giai đoạn 1 tin nhắn gửi bởi Pi, với ts dấu thời gian ban đầu
PROPOSED_TS (j, i, tag, ts)
// Giai đoạn 2 nhắn gửi bởi Pj, với dấu thời gian sửa đổi, để Pi
FINAL_TS (i, tag, ts) // Giai đoạn 3 nhắn gửi bởi Pi, với dấu thời gian thức
(1) Khi quá trình Pi muốn multicast nhắn M với một thẻ tag: (1a) đồng hồ ← đồng hồ + 1;
(1b) gửi REVISE_TS (M, i, tag, đồng hồ) cho tất cả các quy trình; (1c) temp_ts ← 0;
(1d) đang chờ đợi PROPOSED_TS (j, i, tag, tsj) từ mỗi quá trình Pj; (1e) ∀j ∈ N, đừng temp_ts ← max (temp_ts, tsj);
(1f) gửi FINAL_TS (i, tag, temp_ts) cho tất cả các quy trình; . (1g) đồng hồ ← max (đồng hồ, temp_ts)
(2) Khi REVISE_TS (M, j, tag, CLK) đến từ Pj: (2a) ưu tiên ← max (ưu tiên + 1, CLK);
(2b) chèn (M , tag, j, ưu tiên, không gửi được) trong temp_Q;
// vào cuối hàng đợi
(2c) gửi PROPOSED_TS (i, j, tag, ưu tiên) để Pj.
(3) Khi FINAL_TS (j, x, CLK) đến từ Pj :
(3a) Xác định mục Q_e trong temp_Q, nơi Q_e.tag = x;
(3b) đánh dấu Q_e.deliverable là đúng sự thật;
(3c) Update Q_e.timestamp để CLK và tái phân loại temp_Q dựa trên các
lĩnh vực dấu thời gian;
(3d) if (đầu (temp_Q)) tag = Q_e.tag sau đó.
(3e) di chuyển từ Q_e temp_Q để delivery_Q; (3f) trong khi (đầu (temp_Q)). Phân bổ là làm đúng
(3g) đầu dequeue (temp_Q) và chèn vào delivery_Q.
(4) Khi Pi xoá thư (M, tag, j, ts, chuyển giao) từ
đầu ( delivery_Qi):
(4a) đồng hồ ← max (đồng hồ, ts) + 1.
đang được dịch, vui lòng đợi..
 
Các ngôn ngữ khác
Hỗ trợ công cụ dịch thuật: Albania, Amharic, Anh, Armenia, Azerbaijan, Ba Lan, Ba Tư, Bantu, Basque, Belarus, Bengal, Bosnia, Bulgaria, Bồ Đào Nha, Catalan, Cebuano, Chichewa, Corsi, Creole (Haiti), Croatia, Do Thái, Estonia, Filipino, Frisia, Gael Scotland, Galicia, George, Gujarat, Hausa, Hawaii, Hindi, Hmong, Hungary, Hy Lạp, Hà Lan, Hà Lan (Nam Phi), Hàn, Iceland, Igbo, Ireland, Java, Kannada, Kazakh, Khmer, Kinyarwanda, Klingon, Kurd, Kyrgyz, Latinh, Latvia, Litva, Luxembourg, Lào, Macedonia, Malagasy, Malayalam, Malta, Maori, Marathi, Myanmar, Mã Lai, Mông Cổ, Na Uy, Nepal, Nga, Nhật, Odia (Oriya), Pashto, Pháp, Phát hiện ngôn ngữ, Phần Lan, Punjab, Quốc tế ngữ, Rumani, Samoa, Serbia, Sesotho, Shona, Sindhi, Sinhala, Slovak, Slovenia, Somali, Sunda, Swahili, Séc, Tajik, Tamil, Tatar, Telugu, Thái, Thổ Nhĩ Kỳ, Thụy Điển, Tiếng Indonesia, Tiếng Ý, Trung, Trung (Phồn thể), Turkmen, Tây Ban Nha, Ukraina, Urdu, Uyghur, Uzbek, Việt, Xứ Wales, Yiddish, Yoruba, Zulu, Đan Mạch, Đức, Ả Rập, dịch ngôn ngữ.

Copyright ©2024 I Love Translation. All reserved.

E-mail: