does llvm support type checking?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

does llvm support type checking?

kirbature
Recently I was looking up LLVM on net and I stumbled upon a pdf called "2008-05-17-BSDCan-LLVMIntro.pdf". What makes this somewhat general introduction to llvm interesting for me is the fact that it mentions (on page 30 if you are curious) that it supports "Type Checking and Semantic Analysis
- Builds Abstract Syntax Trees (AST) for valid input"!!! I find this surprising because I knew nothing about type checking being implemented in llvm. I am not much of a compiler guy (and I dont know much about llvm), but type checking has always been an amazing idea to me simply because of how many common errors it would prevent from inputs getting messed up. Why isnt it being advertised more? When I googled "llvm + type checking" I just got obscure questions/answers and the term being thrown haphazardly in broad descriptions of the what llvm can do. Is this really a feature that is going/already has been implemented?

-Kirbature

I am sorry if this post seems stupid, but I feel like it is insane if people are not hyping the importance of a feature like this.
Reply | Threaded
Open this post in threaded view
|

Re: does llvm support type checking?

Gordon Henriksen-3
On 2008-07-05, at 23:35, kirbature wrote:

> Recently I was looking up LLVM on net and I stumbled upon a pdf  
> called "2008-05-17-BSDCan-LLVMIntro.pdf". What makes this somewhat  
> general introduction to llvm interesting for me is the fact that it  
> mentions (on page 30 if you are curious) that it supports "Type  
> Checking and Semantic Analysis - Builds Abstract Syntax Trees (AST)  
> for valid input"!!! I find this surprising because I knew nothing  
> about type checking being implemented in llvm. I am not much of a  
> compiler guy (and I dont know much about llvm), but type checking  
> has always been an amazing idea to me simply because of how many  
> common errors it would prevent from inputs getting messed up. Why  
> isnt it being advertised more? When I googled "llvm + type checking"  
> I just got obscure questions/answers and the term being thrown  
> haphazardly in broad descriptions of the what llvm can do. Is this  
> really a feature that is going/already has been implemented?


LLVM does not build ASTs. You were probably reading a description of  
clang, a C compiler built on LLVM.

     http://clang.llvm.org/

LLVM has a low-level type system, but does not attempt to provide a  
safe execution environment like the type systems in a Java VM or  
the .NET runtime. It is detailed in the manual.

     http://llvm.org/docs/LangRef.html

— Gordon


_______________________________________________
LLVM Developers mailing list
[hidden email]         http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev