[LLVMdev] llvm: is it possible to merge semantic validation and compilation in a single stage?

Charllls Alquarra charlesneedspace at yahoo.com.ar
Wed Feb 1 09:05:43 PST 2012


Generally speaking, when writing a llvm frontend, one will take an AST and first check that its semantics is well-defined. After this, one will take the AST and perform the IR build phase.
I was wondering, how realistic is to perform directly the IR build phase onto the AST, and if errors are found during the build process, revert any partial changes to the module object? i assume something like this would be required:
	* remove defined Types
	* remove defined Globals
	* anything else i'm missing?
any ideas about this? what are the general guidelines of what needs to done for a clean revert of module changes after a failed build phase?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120201/10d16a11/attachment.html>


More information about the llvm-dev mailing list