Path: news.ccsf.jp!news.tomockey.net!goblin3!goblin1!goblin.stu.neva.ru!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: YAMAGUTIseisei Newsgroups: tw.bbs.comp.sources,japan.handmade.electronics Subject: jit-1_-_github__ysei~mruby-meta-circular-heiretu_-_nightly_-_2_0_1_7_0_6_3_0__0360710200.rb ( Was : Re: jit-1_-_github__ysei~mruby-meta-circular-heiretu_-_nightly_-_2_0_1_6_0_7_0_7__7070610200.rb ) Followup-To: tw.bbs.edu.computer-science,india.test,fj.comp.ai.alife Date: Tue, 08 Aug 2017 03:18:26 +0000 Organization: X-PlsDntToRmsMatzYktJlgTtiRbistAnd: http://yahoo.jp/UUNk3s?#Sponsor_-_CellBE Lines: 496 Message-ID: <59892D82.4060203@hello.to> References: <54C4B4E9.4080503@hello.to> <54D7DCBA.9080004@hello.to> <54E0B1C1.4000206@hello.to> <54E0B96A.2090205@hello.to> <54E9FF02.8090302@hello.to> <54F326E9.3010908@hello.to> <54FC6769.6090605@hello.to> <550DC230.7030303@hello.to> <5516EBEE.8040901@hello.to> <551A2704.4020109@hello.to> <5529692E.4060609@hello.to> <552D3439.3090107@hello.to> <5534B697.2000800@hello.to> <5545F912.9020803@hello.to> <5550CDAB.8040405@hello.to> <5558C89B.4050103@hello.to> <5561E704.9000208@hello.to> <55645EAA.9040304@hello.to> <55745BE2.5000100@hello.to> <55ACFE56.7040602@hello.to> <55E2830C.9070303@hello.to> <55EBB467.40803@hello.to> <55F4C0BC.5050308@hello.to> <560130D5.4030103@hello.to> <560131AA.9080804@hello.to> <56238C37.5020506@hello.to> <56332C2C.80904@x68k.net> <56360E57.2090200@hello.to> <57CC1CA9.5000107@hello.to> <5954F13B.3030107@hello.to> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-2022-JP Content-Transfer-Encoding: 7bit Injection-Info: mx02.eternal-september.org; posting-host="9ddeab1278eb3d28316223ba4310dba3"; logging-data="6732"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19EjMoPT83ULx/ObZvwvU/t" User-Agent: Mozilla/5.0 (BeOS; U; BeOS BePC; en-US; rv:1.1) Gecko/20020901 X-Accept-Language: ja, en-us Cancel-Lock: sha1:4ZM0jMKSYrp2JimlQhGMac4o8uI= Xref: news.ccsf.jp japan.handmade.electronics:214 23,24d22 < # KS = (0 .. 9).to_a.join + ?- # * '' higokan mruby 70410200 # ?0.upto # higokan mruby 70410200 # 7221410200 6ccae658 suzukaze # q < # Ks = (0 .. 9).to_a.join + ?- # * '' higokan mruby 70410200 # ?0.upto # higokan mruby 70410200 # 7221410200 6ccae658 suzukaze # q 27d24 < # k = Kernel.const_get k 35d31 < # ! ! case k = k.to_s[1] 37c33,34 < when ?r then '[]' == vs[0] + vs[-1] # , Array # q --- > # when ?r then '[]' == vs[0] + vs[-1] # , Array # q > when ?r then '[]' == vs[0] << vs[-1] # , Array # q 39,40d35 < # s = KS + ?i == k ? '' : ?. # Fixnum # q 2 < # s = Ks + ?i == k ? '' : ?. # Fixnum # q 2 42,43c37,40 < @@ks |= (0 .. 9).to_a.join + ?- # * '' higokan mruby 70410200 # ?0.upto # higokan mruby 70410200 # 7221410200 6ccae658 suzukaze # q < ) + ?i == k ? '' : ?. # q 2 --- > # @@ks |= (0 .. 9).to_a.join + ?- # * '' higokan mruby 70410200 # ?0.upto # higokan mruby 70410200 # 7221410200 6ccae658 suzukaze # q > @@ks ||= (0 .. 9).to_a.join << ?- # * '' higokan mruby 70410200 # ?0.upto # higokan mruby 70410200 # 7221410200 6ccae658 suzukaze # q > # ) + ?i == k ? '' : ?. # q 2 > ) << ?i == k ? '' : ?. # q 2 44a42 > when ?y then vs.to_sym == v # Symbol # q 46d43 < # end 68,71c65 < # def pid_g < # $$ || self < # end < # def pid_g() $$ || self end --- > # def pid_g; $$ || self end 88,90d81 < # def asoc < # end < 195c186,192 < @fml.(lb).assoc(sym) # c --- > # @fml.(lb).assoc(sym) # c > @fml.(lb).assoc(sym) || ( # c > # printf("Unkown code %s \n", OPTABLE_SYM[imem.get_opcode(cop)]) > print("Unkown code #{sym} \n") # .to_s > return nil > # raise > ) 197a195,210 > def ta(ta, cop) [ta.shift || 'getarg_a', ta.shift || cop][0 .. ta.pop || 1] end > > # def fvl(oi, th, fv, wd, cop) > # def fva(oi, th, fv, cop) > # [ > # [-> {[fv[oi] = th[oi] = (ta(fv[oi], cop)), []]}, > # -> {th += [[fv[oi] && ta(fv[oi], cop)], []][ > # ((wd = fv.width) <=> oi) >> 1]}][oi <=> 0].call, # .lazy > # th, > # wd > # ] > # ->(oi) {[fv[oi] = th[oi] = (ta(fv[oi], cop)), []]}, # l > # ->(oi) {th += [[fv[oi] && ta(fv[oi], cop)], []] # l > # end > > 205c218,222 < def s__r1_eq_sr01(*a) a[@@I_s__s][ a[@@I_s__r1]] == a[@@I_s__s][a[@@I_s__r0] + 1] end --- > # def s__r1_eq_sr01(*a) a[@@I_s__s][ a[@@I_s__r1]] == a[@@I_s__s][a[@@I_s__r0] + 1] end > def s__r1_eq_sr01(*a) a[@@I_s__s][ a[@@I_s__r1]] == > a[@@I_s__s][ a[@@I_s__r0] + 1] end > # def s__r1_eq_sr01(*a) a[@@I_s__r1] && > # a[@@I_s__s][a[@@I_s__r0] + 1] == a[@@I_s__s][a[@@I_s__r1]] end 208d224 < # knid(op[0], :Numeric) ? op.inject(:+) : self.send(*op) 222a239,242 > ( > # @imem = Imem.new # higokan mruby 80410200 > @@Imem = Imem.new > @@slp = Slp.new 224,234c244,252 < # @imem = Imem.new # higokan mruby 80410200 < @@Imem = Imem.new < < @@fl = '~~ritepl' < @@idb = @@fl < @@fl += '.loc' < # @@idb = 0.pid_g.to_xeh + @@idb # + < # (rand 0xff).to_xeh + < # (Time.now.to_f - 0x3fffffff.to_f << 0x10).to_s.split('.')[0][-8..-1].to_xeh < # @@dlm = '\n' < # @@dlm = '__--__' --- > @@fl = '~~ritepl' > @@idb = @@fl > @@fl += '.loc' > # @@idb = 0.pid_g.to_xeh + @@idb # + > # (rand 0xff).to_xeh + > # (Time.now.to_f - 0x3fffffff.to_f << 0x10).to_s.split(?.)[0][-8..-1].to_xeh # q > # @@dlm = '\n' > # @@dlm = '__--__' > ) 274c292,293 < Slp.new.slp 0 --- > # Slp.new.slp 0 > @@slp.slp 0 408d426 < # bf = 2 ** bfsz - 1 # kakezan 423,429c441,453 < # ([] == a || case a when Array then true end.!) && (return a) # t < a.map! { |v| < ## v.kind_of?(Array) ? __send__(v, pc) : v # unwork ( thread ? ) < # knid(v, :Array) ? __method__(v, pc) : v # unwork ( thread ? ) < # knid(v, :Array) ? __callee__(v, pc) : v # unwork ( thread ? ) < # knid(v, :Array) ? st_id(v, pc) : v < case v when Array then st_id(v, pc) else v end --- > # ([] == a || case a when Array then true end.!) && (return a) # t # higokan mruby70410200 monami-ya.mrb60510200 > # a.map! { |v| > ### v.kind_of?(Array) ? __send__(v, pc) : v # unwork ( thread ? ) > ## knid(v, :Array) ? __method__(v, pc) : v # unwork ( thread ? ) > ## knid(v, :Array) ? __callee__(v, pc) : v # unwork ( thread ? ) > # knid(v, :Array) ? st_id(v, pc) : v > # case v when Array then st_id(v, pc) else v end > a.map! { |a| > ## v.kind_of?(Array) ? __send__(a, pc) : a # unwork ( thread ? ) > # knid(a, :Array) ? __method__(a, pc) : a # unwork ( thread ? ) > # knid(a, :Array) ? __callee__(a, pc) : a # unwork ( thread ? ) > # knid(a, :Array) ? st_id(a, pc) : a > case a when Array then st_id(a, pc) else a end 431c455,456 < return a[0] if 2 > a.size --- > # return a[0] if 2 > a.size > return a[0] if 1 >= a.size 437,439c462,465 < #print "#{pc.to_xeh} #{opc} #{op.to_xeh}\n" if ! knid(opc, :Numeric) < case opc when Numeric then else < print "#{pc.to_xeh} #{opc} #{op.to_xeh}\n" end --- > #case opc when Numeric then else > case opc when Numeric then true end || ( > # print "#{pc.to_xeh} #{opc} #{op.to_xeh}\n" end > print "#{pc.to_xeh} #{opc} #{op.to_xeh}\n") 456c482,483 < th[idx] = st_id(th[idx], pc - 1) --- > th[idx] = st_id(th[idx], pc - 1) ; > #### th[idx] = st_id(th[idx], pc - 1) if ckth(th[idx], 0) # fuguai taisaku 460c487,489 < self.pl_es(pc, ['th', th]) --- > #### if f = (th[idx].nil?.! && ckth(th[mx], 3)) # fuguai taisaku > # self.pl_es(pc, ['th', th]) > pl_es(pc, ['th', th]) 464,465c493,496 < Slp.new.slp 0 < # Slp.new.slp(0, 4096) --- > # Slp.new.slp 0 > @@slp.slp 0 > ## Slp.new.slp(0, 4096) > # @@slp.slp(0, 4096) 467,468c498,499 < idx += f || idx < mx ? 1 : 0 ## < #### idx += f && idx < mx ? 1 : 0 # fuguai taisaku ## --- > # idx += f && idx < mx ? 1 : 0 ## > f && idx += idx < mx ? 1 : 0 ## 476,477c507,511 < flg = true < loop do --- > apc = [] > fpl = [] > # flg = true > flg = [true] > loop { 479c513,514 < pc = self.ctr_g if flg --- > # pc = self.ctr_g if flg > apc<< ctr_g if flg[0] # p 481,482c516,518 < # if pc != cto || ! flg < if 0 <= pc || ! flg --- > # if pc != cto or ! flg > # if pc >= 0 || ! flg > if flg[0].! || (apc.empty?.! && (pc = apc.shift) >= 0) 484c520,521 < f = self.plw(pc) if flg --- > # f = self.plw(pc) if flg > fpl<< plw(pc) if flg[0] # p 490,492c527,530 < # (flg = [true][ith] || false) || (Slp.new.slp 0; redo) ### < # (flg = f.resume) ? f = nil : (Slp.new.slp 0; redo) ## < if ! (flg = f.resume) then Slp.new.slp 0; redo end ## --- > # (flg = [true][ith] || false) || redo ### > # (flg = f.resume) ? f = nil : redo ## > # if ! (flg = f.resume) then redo end ## > fpl.reject!.with_index { |v, n| flg[n] = v.resume} 494c532,533 < Slp.new.slp --- > # Slp.new.slp > @@slp.slp 496c535 < end --- > } 502,504c541,543 < #class ENVary < Array < # include M__ENVary < #end --- > # class ENVary < Array > # include M__ENVary > # end 508c547 < @@m = Mutex.new --- > # @@m = Mutex.new 512,516c551,554 < @s = s < @p = sp < @@m.lock < s = @s < @@m.unlock --- > # @@m.lock > @s = s > @p = sp > # @@m.unlock 521,523c559,563 < # p id = self.object_id < # @p = a[0] if 0 < a.size < @p = a[0] if ! a.empty? --- > # id = self.object_id > # @@m.lock > @p = a[0] unless a.empty? > # p = @p > # @@m.unlock 524a565 > # p 528,533c569,575 < @@m.lock < s = @s < @@m.unlock < # s[@p.ipt a[0]] < # s[@p.sgp a[0]] < s[@p + a[0].sgp] --- > # @@m.lock > @s[@p + a[0].sgp] > # s[@p.ipt a[0]] > # s[@p.sgp a[0]] > # s[@p + a[0].sgp] > # @@m.unlock > # [mloc, @s[@p + a[0].sgp], @@m.unlock][1] 537c579 < @@m.lock --- > # @@m.lock 541,542c583,585 < @@m.unlock < a --- > # @@m.unlock > # a > # [mloc, @s[@p + a[0].sgp] = a[1], @@m.unlock][1] 543a587,592 > > def size; @s.size end > > # def mloc > # begin @@m.lock; rescue Slp.new.slp(0); retry end > # end 597a647 > @@slp = Slp.new 661c711,713 < def fls(pc) ## --- > def fls2(pc, pl = []) ### > # def fls2(pc) ### > # def fls(pc) ## 675,676c727,728 < # sp, wd, isr0, r0, r1, lm, sy = [] # higokan ? mruby 70410200 < # sp, wd, isr0, r0, r1, lm, sy = [][0] --- > # sp, sz, isr0, r0, r1, lm, sy = [] # higokan ? mruby 70410200 > # sp, sz, isr0, r0, r1, lm, sy = [][0] 681,684c733,735 < # wd = 2 < # ap = 0xf - 1; ap = (ap << wd) + ap + (1 << (wd - 1)) >> wd < wd = 4; ap = (1 << wd) - 1 - 1 < wd -= 2; ap = (ap << wd) + ap + (1 << (wd - 1)) >> wd --- > # sz = 4; ap = (1 << sz) - 1 - 1 > sz = 4; ap = 1 << sz > sz -= 2; ap = (ap << sz) + ap + (1 << (sz - 1)) >> sz 687a739 > # lm = ->(isr0, r1) {imem.send(pr, *isr0, r1)} # l 691c743,744 < r = (plr[r1] if 0 <= wd && r1 <= wd) || lm.(isr0, r1) # c --- > # r = (plr[r1] if 0 <= sz && r1 <= sz) || lm.(isr0, r1) # c > r = if r1 <= sz && plr[r1].nil?.! then plr[r1] else lm.(isr0, r1) end # c 695,696c748,753 < # ((sw = sp + wd) + 0xe).step(sw, -1) { # memo # higokan mruby 70410200 # bbab89e7 5211410200 tmtm < wd.step(wd + ap -= ap >> 2) { |n| plr<< lm.(isr0, s[n])} # p c --- > # ((sw = sp + sz) + 0xe).step(sw, -1) { # memo # higokan mruby 70410200 # bbab89e7 5211410200 tmtm > # sz.step(sz - 1 + ap -= ap >> 2) { |n| plr<< lm.(isr0, s[n])} # p c > mx = sz - 1 + ap -= ap >> 2 > s.size < mx && mx = s.size > (mx - sz).times { |n| plr<< lm.(isr0, s[n])} # p c > # (mx - sz).times { |n| s[n] && plr<< lm.(isr0, s[n])} # p c 703,706c760,764 < Fiber.new { < loop do ## < pl = lpl.pl_g(pc) ## < sp ||= s.sp(pl[i_sp][0]) --- > # Fiber.new { ## > # loop { ## > # pl = lpl.pl_g(pc) ## > # sp ||= s.sp(pl[i_sp][0]) ## > sp = s.sp(pl[i_sp][0]) ### 714c772,773 < wd = plr.width --- > # sz = plr.width > sz = plr.size 720,722c779,800 < # return([! flg.include?(false), pl]) ### < Fiber.yield(! flg.include?(false)) ## < end ## --- > return([! flg.include?(false), pl]) ### > # return(! flg.include?(false)) ### > # Fiber.yield(! flg.include?(false)) ## > # } ## > # } ## > end > > def fls(pc) ### > lpl = @pl > i_th = lpl.affil('th', ?i) # q > > flg, pl = true > > Fiber.new { > loop { > flg ? pl = lpl.pl_g(pc) : pl[i_th] = lpl.pl_eg(pc, 'th') > # pl = lpl.pl_g(pc) #### > > flg, pl = fls2(pc, pl) > Fiber.yield(flg) > # Fiber.yield(fls2(pc)) #### > } 727c805,806 < def iset(rg) ## --- > def iset2(rg, thi = 0, th = []) ### > # def iset(rg) ## 735,739c814,818 < fml = imem.fml('th', sym) || ( < printf("Unkown code %s \n", OPTABLE_SYM[imem.get_opcode(cop)]) < return < ) < fmla = fml --- > fml = imem.fml('th', sym) # || ( > # printf("Unkown code %s \n", OPTABLE_SYM[imem.get_opcode(cop)]) > # return > # ) > # fmla = fml 742,743c821 < # ta = ->(l) { [l.shift || 'getarg_a', l.shift || cop][0 .. l.pop || 1] } # l < ta = ->(ta) { [ta.shift || 'getarg_a', ta.shift || cop][0 .. ta.pop || 1] } # l --- > # ta = ->(ta) { [ta.shift || 'getarg_a', ta.shift || cop][0 .. ta.pop || 1] } # l 745,746c823 < < th = [] ## --- > # th = [] ## 749,755c826,829 < # fvl = ->(oi) {[ # l < # -> {[fv[oi] = th[oi] = (ta.(fv[oi])), []]}, # l c < # -> {th += [[fv[oi] && ta.(fv[oi])], []][ # l c < # ((wd = fv.width) <=> oi) >> 1]}][oi <=> 0].call # .lazy < # } < fvl = [->(oi) {[fv[oi] = th[oi] = (ta.(fv[oi])), []]}, # l c < ->(oi) {th += [[fv[oi] && ta.(fv[oi])], []][ # l c --- > # fvl = [->(oi) {[fv[oi] = th[oi] = (ta.(fv[oi])), []]}, # l c > # ->(oi) {th += [[fv[oi] && ta.(fv[oi])], []][ # l c > fvl = [->(oi) {[fv[oi] = th[oi] = (imem.ta(fv[oi], cop)), []]}, # l > ->(oi) {th += [[fv[oi] && imem.ta(fv[oi], cop)], []][ # l 759c833 < fml = fmla.dup --- > # fml = fmla.dup 760a835,836 > i = -1 > # bt[oi].each_slice(2).with_index { |k, i| k, v = k # higokan mruby:70410200 monami-ya.mrb:60510200 762c838,839 < fv = fml.shift --- > # fv = fml.shift > fv = fml[i += 1] 765d841 < # when 'th' then fv = fvl.(oi) # c 766a843 > # when 'th' then (fv, th, wd) = imem.fvl(oi, th, fv, wd, cop) 774c851 < thi = 0 ## --- > # thi = 0 ## 777,778c854,855 < Fiber.new { < loop do ## --- > # Fiber.new { ## > # loop { ## 786c863,864 < Slp.new.slp 0 --- > # Slp.new.slp 0 > @@slp.slp 0 788d865 < # pl.pl_es(pc1, ['sym', 'th', k_sp_r].flat_map { |o| [o]<< ops.shift}) # p 793,795c870,885 < # [thi + 1, th] ### < Fiber.yield(thi += 1) ## < end ## --- > [thi + 1, th] ### > # Fiber.yield(thi += 1) ## > # } ## > # } ## > end > > def iset(rg) > thi = 0 > th = [] > > Fiber.new { > loop { > thi, th = iset2(rg, thi, th) > > Fiber.yield(thi) > } 939,940c1029,1030 < @callinfo[@cp] = rg['sp'] < @cp += 1 --- > # @callinfo[@cp] = rg['sp'] > # @cp += 1 942,943c1032,1033 < @callinfo[@cp] = rg['pc'] < @cp += 1 --- > # @callinfo[@cp] = rg['pc'] > # @cp += 1 945,946c1035,1037 < @callinfo[@cp] = irep < @cp += 1 --- > # @callinfo[@cp] = irep > # @cp += 1 > @callinfo[@cp ... @cp += 3] = [rg['sp'], rg['pc'], irep] 1023c1114,1115 < Slp.new.slp 0 --- > # Slp.new.slp 0 > @@slp.slp 0 1025c1117,1118 < Slp.new.slp --- > # Slp.new.slp > @@slp.slp -- YAMAGUTIseisei ( str_h__namae = { :sei => "山口" , :mei => "青星" } ) http://hello.to/seisei/ mailto:seisei@.68..net tel:081-70-5152-1104 heiwa furiisekkusu 1tu