Hello, I am trying to traverse the GIMPlE statements and identify all pointer differences (i.e., memory load and store). For instance, something like:
**_4* = 0; ... _108 = (signed char *) _107; _109 = **_108*; After some quick searches in the GCC codebase, I am thinking to use the following statements to identify variables like _4 and _108: tree op0 = gimple_op(stmt, 0); // get the left variable if (TREE_CODE (op0) == SSA_NAME) { struct ptr_info_def *pi = SSA_NAME_PTR_INFO (op0); if (pi) { std::cerr << "find a store\n"; return STORE; } } However, to my surprise, variables like _4 just cannot be matched. Actually _4 and _108 will be both treated as "NOT" SSA_NAME, and therefore cannot satisfy the first if condition anyway. So here is my question: 1. How come variables like _4 and _108 are NOT ssa forms? 2. then, what would be the proper way of identifying pointer dereferences, something like *_4 = 0; and _109 = *_108 + 1? Best, Shuai