hi SV-EC, I'm on the point of posting a reference algorithm for the bitstream operators, as promised. However, doing the work has prompted a question: Why the asymmetry between the two directions? Consider the bitstring "abcdef" (where each character symbolically represents a single bit). Now, { << { abcdef } } == fedcba // bit reversal { >> { abcdef } } == abcdef // simple packing So far, so good. But... { << 3 { abcdef } } == defabc // reverse order of slices, // keep order within each slice { >> 3 { abcdef } } == abcdef // simple packing In fact, the [slice_size] operand has absolutely no effect for >>. Was this always the intent? Surely it would be more symmetrical, reasonable and useful for >> likewise to respect the slice size... { >> 3 { abcdef } } == cbafed // keep order of slices, // reverse order within each slice Alternatively, if the [slice_size] operand is ignored by >>, would it not be a smart move to forbid its presence? Thanks -- Jonathan Bromley, Consultant DOULOS - Developing Design Know-how VHDL * Verilog * SystemC * e * Perl * Tcl/Tk * Project Services Doulos Ltd. Church Hatch, 22 Market Place, Ringwood, Hampshire, BH24 1AW, UK Tel: +44 (0)1425 471223 Email: jonathan.bromley@doulos.com Fax: +44 (0)1425 471573 Web: http://www.doulos.com The contents of this message may contain personal views which are not the views of Doulos Ltd., unless specifically stated. -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.Received on Wed Jun 20 13:14:43 2007
This archive was generated by hypermail 2.1.8 : Wed Jun 20 2007 - 13:15:05 PDT