Sun, 9 May 2010 09:51:14 -0700 (PDT)

Related articles |
---|

Decompiler, Expression Propagation, Intermediate Representation proble r3831110n@gmail.com (Rebel Lion) (2010-05-09) |

Re: Decompiler, Expression Propagation, Intermediate Representation pr jsinger@cs.man.ac.uk (Jeremy Singer) (2010-05-11) |

Re: Decompiler, Expression Propagation, Intermediate Representation pr r3831110n@gmail.com (Rebel Lion) (2010-05-13) |

From: | Rebel Lion <r3831110n@gmail.com> |

Newsgroups: | comp.compilers |

Date: | Sun, 9 May 2010 09:51:14 -0700 (PDT) |

Organization: | Compilers Central |

Keywords: | disassemble, question |

Posted-Date: | 09 May 2010 16:05:34 EDT |

Hi guys,

I'm an confused newbie to compilers and have to find some

answers:

(1) Expression Propagation Problem

I'm implementing a decompiler with some data-flow optimizations

therefore I build complex expression from simple assignments e.g.

c = a + b

e = c + d

they will be the following after expression propagation

c = a + b

e = a + b + d

in a situation it's not safe:

c = a + b

e = c + d

a = 1

some_use(e) ; we must forbid the propagation of e = c+d since a = 1

kills c = a + b so does e = c + d

Now is the question: How to efficently/correctly implement this

propagation? What's the analysis' name in theory?

(2) Intermediate Representation

SSA form seems awesome but in reversing engineering, memory, stack,

register alias everywhere. as far as I know, SSA represention for

memory/array is not good because of the complexity of point alias or

deep down halting problem

How to representation of the following memory derference code in

SSA form?

[sp] = a

[sp] = b

or

eax = 123

bx = ax

Also, PUSH/POP is hard to analyze too. e.g.

push 1

b = [sp]

pop a

Discussion: What a good IR for decompilation should be?

(3) Lattice Theory

What the hell it is? Many lecture mentions the lattice. I'm completely

baffled by the mathamatics symbols.

Regards,

Post a followup to this message

Return to the
comp.compilers page.

Search the
comp.compilers archives again.