Skip to Main Content
In the parameterized string matching, a given pattern P is said to match with a substring t of the text T, if there exist a bijection from the symbols of P to the symbols of t. This problem has an important application in software maintenance, where we wish to find the equivalency between two sections of codes. Two sections of codes are said to be equivalent, if one can be transformed into the other by renaming the identifiers and variables. In this paper, we extend parameterized shift-or (PSO) string matching algorithm (Kimmo Fredriksson & Maxim Mozgovoy, 2006) by using the concept of super alphabets. This new algorithm we call as parameterized super alphabet shift-or (PSSO) algorithm. Implementation results show that by using a super alphabet of size s, the PSO algorithm is speeded-up by a factor of s, where s is the size of the super alphabet (i.e. s is the number of characters processed simultaneously). We also show the performance of PSSO algorithm with respect to duplicity present in the code. However, PSSO algorithm is applicable only when pattern length (m) is less than or equal to word length (w) of computer used (i.e. m les w).