If TaintInfo doesn't have ConcreteMemoryAddress calculated, that doesn't mean it is not
a memory location (in some cases the ConcreteMemoryAddress is not available).
Current implementation of operator== for TaintInfo has a problem to determine which TaintInfo
is a memory address since it relies on existence of ConcreteMemoryAddress.
In the example below, current implementation would just compare the registers,
since both TaintInfos don't have ConcreteMemoryAddress calculated.
This is tested in the new unittest added to inspect Taint Info management
during TaintAnalysis. I have a plan to add more cases for TaintInfo equivalence
testing.
New implementation of operator== relies on existence of Offset instead of ConcreteMemoryAddress.
Additionally, it makes code more readable and separates handling of different TaintInfo types
(memory locations vs registers).
If TaintInfo doesn't have ConcreteMemoryAddress calculated, that doesn't mean it is not a memory location (in some cases the ConcreteMemoryAddress is not available). Current implementation of operator== for TaintInfo has a problem to determine which TaintInfo is a memory address since it relies on existence of ConcreteMemoryAddress.
In the example below, current implementation would just compare the registers, since both TaintInfos don't have ConcreteMemoryAddress calculated.
This is tested in the new unittest added to inspect Taint Info management during TaintAnalysis. I have a plan to add more cases for TaintInfo equivalence testing.
New implementation of operator== relies on existence of Offset instead of ConcreteMemoryAddress. Additionally, it makes code more readable and separates handling of different TaintInfo types (memory locations vs registers).