1. Trang chủ
  2. » Thể loại khác

Otomat khoảng trong lập lịch các chương trình cho hệ thống máy tính phân cụm

11 0 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 11
Dung lượng 259,37 KB

Nội dung

Journal of Computer Science and Cybernetics, V.27, N.3 (2011), 218-228 DURATION AUTOMATON IN SCHEDULING PROGRAMS FOR A CLUSTER COMPUTER SYSTEM* BUI VU ANH Faculty of Mathematics, Mechanics and VNU University of Science Informatics Tdm t i t L§,p lich toi Uu cho cac cdng viOc: ch9,y tr6n cdc mdy, trUdng hpp ting qudt, \h mOt bdi to4n khd va khong c6 thu(it todn thUc hifn thdi gian da thflc Cdc giai phdp tii Uu vk xip xi toi Uu (lli giai qnyh cho cac trUdng hpp riSng vdi cdc rdng buOc hgn che Thugt toan Igp ljch trgn va may dupc cong l)o d [I 16] dUpc xem nhU nhiing khdi diu Trong [16], tdc gii giai bdi toliii cong vice qud hQ,n co tinh den thdi gian chuan bj [4] gidi bdi todn cdn^f vi$c den hg,n tren trudng hpp hai may, \k c6 the nid rpng cho trUdng hpp mdy vdi mpt so dieu kign trSn cong vifc Cac tic gia khdc cung xcni xet cac bdi todn Igp ljch d cdc trUdng hpp rifng nhU [5, 8, 17] Bdi bdo utng dung mo hinh otomat khoang (Duration Automaton DA) [1, 2] giai quyet bai todn Igp ljch dpng cho cac cong vifc vdi thdi gian xfl ly khong chic chin tren may tinh ghep cym hf thong gim nliieu mdy tfnh (not tinh todn) phoi hpp ldm vifc vdi Chiing toi xet cum may tinh hai tnfdng hdp: cdc may giing va khdc ve ciu hinh (tdi nguyen ciia mdy tinh, mpt cdch hinh thutc dupc quy ve cau hinh, the hifn qua thdi gian xfl ly cong vifc) Do khong biet trUdc thdi gian hoan mdi cong vifc, cac thuat todn toi Uu da cd se khong dupc dp dyng mpt each hifu qua Th6ng qua viec mo hinh hda va sfl dung tifu chuan ve thfl tU ciia otomat khoang, chiing toi de xuat thuat todn lap lich va thUc nghiem cho thiy cd ket qua t i t ve thdi gian hoan cdc cong vifc so vdi cdc phUdng phdp truyin thong nhu FIFO (hang dpi tu nhien), hdng dpi cong vifc vdi tieu chuin hoan nhanh trudc (tiep can tham lam), hodn lau trudc (tiep cgn an toan) khong ding bo A b s t r a c t Optimal schedule for works running on machines, in a general case, is a hard problem and there is no complete optimal deterministic algorithm in polynomial time Optimal and approximated solutions were issued for some specific cases with constraints One can find the solutions for the cases and machines [4, 16] as the initial algorithms In [16], author solved late works problem using algorithm with setup times included [4] solve the due works problem on two machines, and can be extended for the case of machines with some conditions on works Other authors looked at schedule problems in specific cases like [5, 8, 17] In this paper, we apply duration automata [1, 2] to solve the schedule problem dynamically for the works with uncertain processing time in a cluster computer, which is a system consisting of many computers (computing nodes) co-working together We solve the schedule problem in a cluster with m machines for two cases: all machines are the same and different in configurations (machine's resources are formally considered as a configuration information, represented by the time need to finish the works) Because of uncertainly processing time, tranditional algorithms can not be used effectively By using DA model with DA's order criterion, we issue schedule algorithms and practically prove to be better in time consuming compare to FIFO (natural order), the fastest first (greedy) and the longest first (safety) methods without synchronized points *This paper was supported by Hanoi University of Science (grant TN-10-05) DURATION AUTOMATON IN SCHEDULING PROGRAMS FOR A CLUSTER COMPUTER SYSTEM 219 INTRODUCTION Formal tools are usually used to model systems [1, 2, 3, 9, 10] DA is a traditional automaton which is augmented with a clock variable and a timed duration constraint on each transition [1, 2] The labels (or actions) of transitions are separated into three types: input, output, and internal comparing to internal and external actions of the 10 automata [11, 12, 13] This automaton is less complex than timed automaton [9] but more flexible in reality comparing to 10 automata [11] We have used DA to model component-based real-time systems, real-time objects modeling, and embedded systems with timed and untimed specifications [2], priority networks [1] In this paper, we use DA to model a cluster computer system where its nodes can be controlled by a master one (head node) or worked independently, and solve the scheduling problem Scheduling works on machines, with many kind of constraints on work's order, is a difficult problem and there is no optimal solution in polynomial time Some special cases had been risen by [4, 16] and there were good solutions (gready approach) but they are really simple to be widely used Recent reseaches have been moved to the application aspect in serveral cases Authors in [5] concentrated on the problem of two machines in which works came over the time There is an improved issue [7] works on two machines with the availability constraint In [8], authors solved problem on two machines with the view of fuzzy-set theory; and author in [17] developed a 3/2—algorithm to solve the problem in [16] again In this paper, we look at the problem with the view of DA, and consider the problem in a different aspect: schedule uncertain processing time works for machines In special cases, our problems will turn into the problem in [16, 8, 7] when the processing times are defined We also issue criteria which is used to develop algorithms solving these problems DURATION AUTOMATON D e f i n i t i o n A duration a u t o m a t o n is a tuple M = {S, E, A , V, q, R, F) where: • 5" is a finite set of states, g G is an initial state In a general case, q can be a set • E, A , V are internal, input and output alphabet of actions (or labels) We denote the set of actions of DA b y > l = S U A U V There is an empty action e G S • RC S X A X domain x S is a set of transitions, where domain = {[l,u],{l,u],[l,u),{l,u) \ I, u E Z + , / < u} For each transition e = (s, a, d, s') E R, a will be an output action of s and input action of s' as well If s = s' then e is a ring • F C is a set of final (or accepted) states We denote by ( M ) , E ( M ) , A ( M ) , V ( M ) , R{M), F ( M ) the corresponding components of M , and A{M) = E ( M ) U A ( M ) U V ( M ) For s G S{M), E ( s ) , A ( s ) , V(s) are the internal, input and output actions of the state s respectively A configuration of M is a couple {s,t), where s E S,t E R"^ which shows that M reaches the state s and stays there at the time t So that, initial configuration of M is {q, 0) As the time passes, the changes of M are of the following forms: Time-change: {s,t) - ^ {s,t-\- a) where a E R"*", a E Il(s) Automaton stays at state s and does its internal actions 220 I*'" VU ANH State-change: {.s,t) ^ {s'j + a) where a E R + , a G A(s), using transition {s,a,d,s') € R{M), t-\-o Ed The transition can take |)la,ce if the time constraint on the arc between s and s' be satisfied We make an extra assumption that internal act.ions takes no time It can finish at a small enough time that can be ignored and we only concentrate on input and output actions Hinh 2.1 Example of duration automaton Definition 2.2 Let M be a DA and p be a sequence (so,0), {s\,di), (52,^2), • • {sn,dn), p = {si, di)i=o„n in short, be a sequence of changes If p satisfies SQ = is the initial state, and for each < i < n, 3ei E R : Ci = {si-i, a,, dj, Sj) which makes M move from Sj_i to Si, then it is called a d-path from SQ to Sn in M p is a d-path If there is a strictly increasing sequence to = 0,^1,^2, ,*n such that for alH, < i < n: ti - ti-x E di then p = (SQ, 0), (si, ti), (s2, ^2), • • (sn, U), {si, «i+i)i=o n '^ short, is ealled an t-path of p d-path with t-path and Sn E F is ealled a successful path of M.w= (ai, dl), (02, di), (03, ds), • • (^n, dn), {oi, di)i=i n in short, where a^ is the action of the transaction Ci of p, is a d-word and ti; = (oi, fi), (02, ^2), ("3, *3)> • • • {o-n^ tn), (ot,*i)i=i ii in short, is ealled a t-word of p - A d-word {y is acceptable (or d-word of M) if there is at least one t-word W of w We say w takes M from SQ to s^, and ty can take M from SQ to Sn- Each {a,.di) is called an atom The d-word VJ without t-word is called unacceptable The d-word HJ is accepted by M if it is a d-word of a successful path All accepted words of M is called a d-language of M, denoted by C{M) Definition 2.3 Given a DA M — (5, E, A, V,g,/?, F ) The projection of M over a realtime value t is M ' = (5, E, A, V,?, i?', F) where the transitions relationship specified as R'= {{s,a,s')\{s,a,d,s') E R, t E d} As the time passes, the projection operator will give an imagination of DA at a time we observe Assume M = (5, E, A, V, q, R, F) is a DA We add a global clock x, which runs regularly, automatically and can be reset to the initial state, and a function / defined as: for each e = (s, a, d, s') € R, /(e) = (s, a, s', A, 5e) where A = {x} and 6e = {x E d) Let R' be {/(e) | Ve G R} Because / is an 1-1 function between R and R', so that T = (EU AU V, S, q, X, R', S, F) for S = {6e, e E R}, X — {x} is a unique corresponding time automaton accepting the same language as DA Thus, DA is a specific class of time automaton [9] We can use time automaton's tools to check for every tim^ properties of DA As a consequence of [9], we will have the following theorem Theorem The reachable and emptiness problems of DA is decidable DURATION AUTOMATON IN SCHEDULING PROGRAMS FOR A CLUSTER COMPUTER SYSTEM 221 CLUSTER SYSTEM MODELING A computing node (computer) can be modeled with a DA, where states of the node will be the states of DA, and the changes between states of the node are the arcs of DA Nodes can have their own internal actions which are separated from one other physically That results internal actions of nodes belong to themselves and they can the same (shared) action at a time but independently Each node can execute a compiled program (called a work) which is modeled as an atom, which can not be divided into the smaller one, {id, d) where id is a work identifier, d = [l,u], I < u, l,u E Z Ms an estimated amount of time to finish the work, and u is the maximum amount of time that work must finish, it can be infinitive to show that work can run as long as it needs The program should finish at time t inside d and {id, t) is called a transition of a node at time t When a node is ready to receive a work, we said that the node is in ready state If a node is doing a work, the state will be busy In case a node can not receive any work, it is in /ailure state and can only be ready again by doing reset action This action can be taken place at any time to make the node from any state to ready state and is not in the action set of any node Each node has an empty action £, i e the node stays at the ready state (or does its internal actions) which is supposed can be finished at any time, empty work has the special form {id, [0, oo)), which means that it takes time to finish Practically, we not have to care much about this action because it can be considered as internal to that node The state before the first time in ready is initial at time ^o = D e f i n i t i o n Suppose t h a t there is a computing node M Let x = {idi, di), {id2, di), • • , {idn,dn) If there exists an instance x = {idi,ti),{id2,t2),-• ,{idn,tn) which makes M tn — i n - i £ d„ change from a r e a d y s t a t e to a ready state and ti G di, ti — ti E di, then x is said t o be a word of M All the word of M is called a language of M and denoted by £ ( M ) For two words x, y of M, we denote x'~"y as a word generated by appending y after x (connect operator) C o r o l l a r y Ifx, y are words of M then x^y is also a word of M Chiing minh Assume x and y are words of M but x'^y is not, so t h a t there is a work {id, d) in x""y which does not bring M from ready state to ready state, (id, d) in x""y implies {id, d) in x or {id, d) in y It means {id, d) can not bring M from ready state to ready state in either x or y (conflicts with assumption x and y are words of M) By corollary 3.1, if x and y are the words which run on M one after another, then we can append y after x to make a new compound word and run it on M D e f i n i t i o n ( l ^ o r k relationship) For two works w = (id, \l, u]) and w' — {id', [V, u']) • w = ^ ^ w' iff {V = 1) A {u = u') • w is smaller t h a n w' (written as w < ^ ^ w' or ^' 2 w' >^^ w) m ( — - — > —^) ' • ISw = p ^ w' and w < ^ ^ w', we write w ^^ w V 222 BUI VU ANH Theorem 3.1

Ngày đăng: 08/12/2022, 21:36

TÀI LIỆU CÙNG NGƯỜI DÙNG

TÀI LIỆU LIÊN QUAN

w