OSDev.org

The Place to Start for Operating System Developers
It is currently Thu Mar 30, 2017 10:41 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: porting LLVM
PostPosted: Sat Jun 18, 2016 6:56 am 
Offline

Joined: Sat Jun 18, 2016 4:45 am
Posts: 1
Hi,



I see that quite a few members here have had success porting gcc to there own operating systems.

I was wondering if anyone has been able to port LLVM and or Clang ? I have found this page (http://wiki.osdev.org/User:MessiahAndrw ... _Toolchain) on the wiki but obviously the section I would be interested in has not been written yet.

I have been working for the last few months on my own C compiler, the idea being that I would be able to use it to develop my kernel and userspace. However I have recently become a little bit more perceptive to the idea of using LLVM and or clang.

My thinking around the design of my OS is evolving and I think I would like to experiment a bit with language design - I have not decided yet exactly what the best course of action is.

I may decide to use my existing C front-end on top of LLVM or I am toying with the idea of designing a new language again using LLVM as a backend.

It would be very helpful to my though processes if someone could provide any information they have regarding porting LLVM to a new OS. Any information on porting clang would also be good.

Ultimately I want my os to be self hosting so If I choose LLVM I’ll have to port clang at some point so that I can build LLVM.

Thanks!


Top
 Profile  
 
 Post subject: Re: porting LLVM
PostPosted: Sat Jun 18, 2016 10:10 am 
Offline
Member
Member
User avatar

Joined: Wed Oct 18, 2006 3:45 am
Posts: 9228
Location: An der schönen blauen Donau, watching muppets
I would imagine the result to be a tradeoff between cleaner code/design and longer histories of documentation for the llvm / gnu chains respectively. Probably the observed ease of porting would end up being a matter of personal opinion. If your hunch is to port LLVM, you might just as well stick with it.

But for now, you sound like you're not even close to going self-hosted. Both GCC and LLVM work in the end, so you should focus initially on getting those other choices sorted out.

_________________
"Certainly avoid yourself. He is a newbie and might not realize it. You'll hate his code deeply a few years down the road." - Sortie
[ My OS ] [ VDisk/SFS ]


Top
 Profile  
 
 Post subject: Re: porting LLVM
PostPosted: Thu Oct 27, 2016 3:19 am 
Offline
Member
Member

Joined: Tue Mar 04, 2014 5:27 am
Posts: 737
masterhipsterjedi wrote:
Ultimately I want my os to be self hosting so If I choose LLVM I’ll have to port clang at some point so that I can build LLVM.


If you're not overly ambitious or if you want it done quicker, you can port something smaller and simpler. There's LCC. There's PCC. There's Bellard's TCC. There's my Smaller C.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group