OSDN Git Service
(root)
/
splhack
/
AndroidRuby.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
ruby-1.9.1-rc1
[splhack/AndroidRuby.git]
/
lib
/
ruby-1.9.1-rc1
/
sample
/
drb
/
speedc.rb
1
#!/usr/local/bin/ruby
2
3
uri = ARGV.shift || raise("usage: #{$0} URI")
4
N = (ARGV.shift || 100).to_i
5
6
case uri
7
when /^tcpromp:/, /^unixromp:/
8
require 'romp'
9
10
client = ROMP::Client.new(uri, false)
11
foo = client.resolve("foo")
12
when /^druby:/
13
require 'drb/drb'
14
15
DRb.start_service
16
foo = DRbObject.new(nil, uri)
17
end
18
19
N.times do |n|
20
foo.foo(n)
21
end