On Monday 23 November 2009 09:01, Anton Korobeynikov wrote:> Hello > > > It is a RISC with around 60 instructions like a 80c51 instruction set > > (without mul/div) and with Direct or indirect memory acces. > > My estimate is something like a man-week for a person, who knows what to do > :)That's pretty optimistic, even for someone who knows what to do. The learning curve for TableGen is quite steep. I would budget at least a year for everything; learning TableGen, writing patterns, custom lowering, testing, etc. And that's for a relatively simple, orthogonal ISA. Of course this happens iteratively. You learn a little TableGen (mostly by looking at existing backends and asking lots of questions), write a few patterns, learn a little more and so on. -Dave
Hello, David> That's pretty optimistic, even for someone who knows what to do.It depends on the target. If it is pretty straightforward, than you can do almost all the stuff automatically. The estimate I provided was the real time for first working version for msp430 backend. If it is just 'normal' RISCy architecture and one should not care about ABI weirdness (this is usually true for MCUs), then the estimate is correct. You just provide patterns for all the operations, expand everything unsupported. After that you need to write bunch of libcalls and first version is ready :) Surely, optimization stuff & supporting of some "nice" features will require much more time. -- With best regards, Anton Korobeynikov Faculty of Mathematics and Mechanics, Saint Petersburg State University
On Tuesday 24 November 2009 10:57, Anton Korobeynikov wrote:> If it is just 'normal' RISCy architecture and one should not care > about ABI weirdness (this is usually true for MCUs), then the estimate > is correct. You just provide patterns for all the operations, expand > everything unsupported. After that you need to write bunch of libcalls > and first version is ready :)Which is straightforward once you know what you're doing. Before that point, however, it's very non-trivial. Basically I'm saying our documentation needs a lot of work. :) -Dave
On Nov 24, 2009, at 8:30 AM, David Greene wrote:> On Monday 23 November 2009 09:01, Anton Korobeynikov wrote: >> Hello >> >>> It is a RISC with around 60 instructions like a 80c51 instruction set >>> (without mul/div) and with Direct or indirect memory acces. >> >> My estimate is something like a man-week for a person, who knows what to do >> :) > > That's pretty optimistic, even for someone who knows what to do. > > The learning curve for TableGen is quite steep. I would budget at least a > year for everything; learning TableGen, writing patterns, custom lowering, > testing, etc.1 year is an eternity in LLVM year. ARM target was up and functional in about 2 months of time. Evan> > And that's for a relatively simple, orthogonal ISA. > > Of course this happens iteratively. You learn a little TableGen (mostly by > looking at existing backends and asking lots of questions), write a few > patterns, learn a little more and so on. > > -Dave > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
I won't work at full time on this project and I fear the first week is used to read documentations :) The better way to have an idea is to start backend developement. I'll try to work on this backend for a month and will see if I'm on the right way. 2009/11/24 Evan Cheng <evan.cheng at apple.com>> > On Nov 24, 2009, at 8:30 AM, David Greene wrote: > > > On Monday 23 November 2009 09:01, Anton Korobeynikov wrote: > >> Hello > >> > >>> It is a RISC with around 60 instructions like a 80c51 instruction set > >>> (without mul/div) and with Direct or indirect memory acces. > >> > >> My estimate is something like a man-week for a person, who knows what to > do > >> :) > > > > That's pretty optimistic, even for someone who knows what to do. > > > > The learning curve for TableGen is quite steep. I would budget at least > a > > year for everything; learning TableGen, writing patterns, custom > lowering, > > testing, etc. > > 1 year is an eternity in LLVM year. ARM target was up and functional in > about 2 months of time. > > Evan > > > > > And that's for a relatively simple, orthogonal ISA. > > > > Of course this happens iteratively. You learn a little TableGen (mostly > by > > looking at existing backends and asking lots of questions), write a few > > patterns, learn a little more and so on. > > > > -Dave > > _______________________________________________ > > LLVM Developers mailing list > > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev > > > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20091124/1824308c/attachment.html>
On Nov 24, 2009, at 1:12 PMPST, Evan Cheng wrote:> On Nov 24, 2009, at 8:30 AM, David Greene wrote: > On Monday 23 November 2009 09:01, Anton Korobeynikov wrote: >>> Hello >>> >>>> It is a RISC with around 60 instructions like a 80c51 instruction >>>> set >>>> (without mul/div) and with Direct or indirect memory acces. >>> >>> My estimate is something like a man-week for a person, who knows >>> what to do >>> :) >> >> That's pretty optimistic, even for someone who knows what to do. >> >> The learning curve for TableGen is quite steep. I would budget at >> least a >> year for everything; learning TableGen, writing patterns, custom >> lowering, >> testing, etc. > > 1 year is an eternity in LLVM year. ARM target was up and functional > in about 2 months of time. > > EvanAnd after a year much of what you learned is going to be obsolete...
On Tuesday 24 November 2009 15:12, Evan Cheng wrote:> > The learning curve for TableGen is quite steep. I would budget at least > > a year for everything; learning TableGen, writing patterns, custom > > lowering, testing, etc. > > 1 year is an eternity in LLVM year. ARM target was up and functional in > about 2 months of time.Yes, from people who already knew TableGen. And did that include testing and all the stuff that goes into hardening and making it production-ready? It's no sin to admit that TableGen is complex. It's a powerful tool. -Dave