I am totally new to unix and perl. Although I have gone thtough some basics of both, I am still not quite comfortable with using them. I have received the following assignment. Can anyone pls help:
[
filename: compareLib.pl
Lib1
Cell : AND1
A1 A2 Y
Cell : INV1
A Z
Lib2
Cell : AND1
A B Y
Cell : INV2
A Z
expected o/p:
compareLib.pl <Lib1> <Lib2>
- INV1 missing in LIB2
- INV2 missing in LIB1
- AND1/A1 missing in LIB2
- AND1/A2 missing in LIB2
- AND1/A missing in LIB1
- AND1/A missing in LIB1
open Lib1
match for cell string : get cell name in a variable
match for pin names : $hash1{$cell}{$ pin}=1;
open Lib2
match for cell string : get cell name in a variable
match for pin names : $hash2{$cell}{$ pin}=1;
Iterate through hash1 and check is exists in hash2 or not. If not report missing...
Iterate through hash2 and check is exists in hash1 or not. If not report missing...
]
I shall be great full for any help on this.
thanx
[
filename: compareLib.pl
Lib1
Cell : AND1
A1 A2 Y
Cell : INV1
A Z
Lib2
Cell : AND1
A B Y
Cell : INV2
A Z
expected o/p:
compareLib.pl <Lib1> <Lib2>
- INV1 missing in LIB2
- INV2 missing in LIB1
- AND1/A1 missing in LIB2
- AND1/A2 missing in LIB2
- AND1/A missing in LIB1
- AND1/A missing in LIB1
open Lib1
match for cell string : get cell name in a variable
match for pin names : $hash1{$cell}{$ pin}=1;
open Lib2
match for cell string : get cell name in a variable
match for pin names : $hash2{$cell}{$ pin}=1;
Iterate through hash1 and check is exists in hash2 or not. If not report missing...
Iterate through hash2 and check is exists in hash1 or not. If not report missing...
]
I shall be great full for any help on this.
thanx
Comment