Sha256: b85972e2c88cb9f5b349d91ec5889df63f9d6b61f34396a5cf04f80e0b2e84f8
Contents?: true
Size: 1.86 KB
Versions: 37
Compression:
Stored size: 1.86 KB
Contents
require 'pathname' module OrigenTesters module SmartestBasedTester class Base class PatternMaster include OrigenTesters::Generator attr_reader :flow, :paths attr_accessor :filename, :id def initialize(flow = nil) @flow = flow @paths = {} end def filename @filename || flow.filename.sub('.tf', '.pmfl') end def subdirectory 'vectors' end def paths { '../vectors' => patterns } end # def add(name, options = {}) # name, subdir = extract_subdir(name, options) # name += '.binl.gz' unless name =~ /binl.gz$/ # # Don't want to ask Origen to compile these, but do want them in the v93k # # compile list # if name =~ /_part\d+\.binl\.gz$/ # Origen.interface.pattern_compiler.part_patterns << name # else # Origen.interface.referenced_patterns << name # end # paths[subdir] ||= [] # # Just add it, duplicates will be removed at render time # paths[subdir] << name unless paths[subdir].include?(name) # end def patterns (references[:subroutine][:all] + references[:subroutine][:ate] + references[:main][:all] + references[:main][:ate]).map do |p| p = p.strip p += '.binl.gz' unless p =~ /binl.gz$/ end.uniq end def references Origen.interface.all_pattern_references[id] end private def extract_subdir(name, options = {}) p = Pathname.new(name.to_s) name = p.basename.to_s subdir = p.dirname.to_s # if subdir == '.' # # In future may support setting a default subdir via the interface # end [name, subdir] end end end end end
Version data entries
37 entries across 37 versions & 1 rubygems