xubingyue / softart

Automatically exported from code.google.com/p/softart
Other
0 stars 0 forks source link

Constant expression llvm code generation support (1) #37

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Constant expression could be translated to llvm value tree.
In this issue, we need implements following things:

 - Semantic analysis:
  - Make sure the expression is a constant expression. Now we need support literal constant and expression composited by it only. Constant variable consider later.
  - Translate value to llvm supported, and save them in a instance of class "constant semantic info"

 - Code generation:
  - translate literal constant value to llvm::Value object, and construct the expression tree.

 - Write test about it.

And the type of literal constant we only support int32 & uint32.
More types support will be added later.

Original issue reported on code.google.com by wuye9036 on 20 Sep 2010 at 4:38

GoogleCodeExporter commented 8 years ago

Original comment by wuye9036 on 20 Sep 2010 at 4:41

GoogleCodeExporter commented 8 years ago

Original comment by wuye9036 on 7 Mar 2012 at 2:58