Sha256: 39be7d439cfdea9045bef9c565dfa9550df0e39070af9d6ae94f4b0067d59499

Contents?: true

Size: 603 Bytes

Versions: 180

Compression:

Stored size: 603 Bytes

Contents

require 'benchmark'
require_relative "../../lib/public_suffix"

JP   = "www.yokoshibahikari.chiba.jp"

TIMES = (ARGV.first || 50_000).to_i

# Initialize
class PublicSuffix::List
  public :select
end
PublicSuffixList = PublicSuffix::List.default
PublicSuffixList.select("example.jp")

Benchmark.bmbm(25) do |x|
  x.report("select jp") do
    TIMES.times { PublicSuffixList.select("jp") }
  end
  x.report("select example.jp") do
    TIMES.times { PublicSuffixList.select("example.jp") }
  end
  x.report("select www.example.jp") do
    TIMES.times { PublicSuffixList.select("www.example.jp") }
  end
end

Version data entries

180 entries across 162 versions & 20 rubygems

Version Path
tdiary-5.2.4 vendor/bundle/ruby/3.1.0/gems/public_suffix-5.0.0/test/benchmarks/bm_select_incremental.rb
whitelabelmachinename-ruby-sdk-3.2.1 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
wallee-ruby-sdk-3.2.0 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
postfinancecheckout-ruby-sdk-3.2.0 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
cloudsmith-api-1.142.3 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.0/test/benchmarks/bm_select_incremental.rb
wallee-ruby-sdk-3.1.5 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
postfinancecheckout-ruby-sdk-3.1.5 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
tdiary-5.2.3 vendor/bundle/ruby/3.1.0/gems/public_suffix-5.0.0/test/benchmarks/bm_select_incremental.rb
whitelabelmachinename-ruby-sdk-3.2.0 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
whitelabelmachinename-ruby-sdk-3.1.9 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
whitelabelmachinename-ruby-sdk-3.1.8 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
cloudsmith-api-1.120.3 vendor/bundle/ruby/2.6.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
whitelabelmachinename-ruby-sdk-3.1.7 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
whitelabelmachinename-ruby-sdk-3.1.6 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
whitelabelmachinename-ruby-sdk-3.1.5 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
postfinancecheckout-ruby-sdk-3.1.4 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
whitelabelmachinename-ruby-sdk-3.1.4 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
wallee-ruby-sdk-3.1.4 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
wallee-ruby-sdk-3.1.3 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb
whitelabelmachinename-ruby-sdk-3.1.3 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/test/benchmarks/bm_select_incremental.rb