Comparing two files line by line
- From: "Niv" <kev.parsons@xxxxxxxxxx>
- Date: 14 Jul 2006 06:51:01 -0700
I have a stimulus file with 3 digit hex numbers and a results file also
with 3 digit hex numbers (The rtesults file has already gone through
one tcl script to get the results into the same format as the
stimulus).
The results file may be longer than the stimulus file due to default
results once stimulus has expired (This is for a VHDL testbench).
The files are not too long, probably < 100 lines.
So how do I compare the files line by line, until stimulus finished,
then check any extra lines in results are default?
The only way I see is to read each file line by line into two separate
lists & then work on the lists.
I don't think the while { [gets $f1 inline1] >= 0}
{ will work, as how do I get the data-line from $f2?
Is there a simpler way?
TIA, Niv.
.
- Follow-Ups:
- Re: Comparing two files line by line
- From: Darren New
- Re: Comparing two files line by line
- From: Bruce Hartweg
- Re: Comparing two files line by line
- Prev by Date: Re: A question on using a namespace
- Next by Date: Re: shouldn't http::formatQuery be slightly modified
- Previous by thread: A question on using a namespace
- Next by thread: Re: Comparing two files line by line
- Index(es):
Relevant Pages
|