Page 1 of 40

TailBite 1.0 Preview, soon in PureProject and PureArea

Posted: Mon Mar 08, 2004 3:36 pm
by El_Choni
Hi,

TailBite is a tool that splits the PureBasic.asm file generated by PureBasic 3.81 for Windows from a .pb source file into several ASM files, and compiles them into a PureBasic library using different tools included with PureBasic.

If you don't know what a PureBasic library is, you don't need TailBite. If you know, ask yourself if you really need TailBite ;) Use it for good, and not for evil.

I've uploaded a Preview Version to <a href="http://pureproject.reelmedia.org">Pure Project</a> and <a href="http://www.purearea.net">Pure Area</a>, and I guess it will be available soon from these links.

The old links for downloading TailBite beta versions are still valid, but they have only that: old beta versions, so you should better download the new version from these sites.

Any feedback, suggestions and bug reports are welcome. Regards,

Re: TailBite 1.0 Preview, soon in PureProject and PureArea

Posted: Mon Mar 08, 2004 7:35 pm
by GPI
El_Choni wrote:Hi,

TailBite is a tool that splits the PureBasic.asm file generated by PureBasic 3.81 for Windows from a .pb source file into several ASM files, and compiles them into a PureBasic library using different tools included with PureBasic.
hmm, can you add a mark to the library, so everybody can see quick, that this lib is generated with TileBite and is not a good programmed assembler library?

Re: TailBite 1.0 Preview, soon in PureProject and PureArea

Posted: Tue Mar 09, 2004 1:12 am
by PB
> hmm, can you add a mark to the library, so everybody can see quick, that
> this lib is generated with TileBite and is not a good programmed assembler
> library?

I second this -- I think it's VERY important!

Posted: Tue Mar 09, 2004 1:21 am
by Shannara
1. I vote against that, since I'm against unneeded segregation, and dont know why people would assume ASM code generated in Tailbite/PB is worse then hand-created ASM.

Or... could you add a trigger so that people have the option to mark such libraries as created in PB? This way, those of us who create libraries won't be considered "tainted" by those who want segregation.

2. GPI/PB: Why do you guys want segregation? I asked the same question in another thread that Fred commented in, however nobody was able to answer..

3. Will tailbite create Linux libraries?

Posted: Tue Mar 09, 2004 4:21 am
by scurrier
Hand made ASM files are a lot faster than what PB does. maybe they should be maybe something like hand made and PB/C++ made cause PB is as fast if not faster than C/C++



Sean

Posted: Tue Mar 09, 2004 5:05 am
by Shannara
scurrier wrote:Hand made ASM files are a lot faster than what PB does. maybe they should be maybe something like hand made and PB/C++ made cause PB is as fast if not faster than C/C++



Sean
I admit that some hand-made ASM is faster then PB (not all..), but then again, how does PB make it's ASM files? ... ah.. hand made.. by Fred..... I do not see how that argument works.. ? ??

Posted: Tue Mar 09, 2004 6:18 am
by Dare2
Re marking - I don't think it matters.

For most, if the lib does what is wanted, it will be used. If not, it wont be.

So if some sort of marking is desired for technical reasons or reasons of status, let it be so. Who cares.

Posted: Tue Mar 09, 2004 3:52 pm
by El_Choni
I thought of using that mark thing, wouldn't be difficult. But it wouldn't be difficult to strip it out in the sources and recompile TailBite. Anyway, I don't know why anybody would want to hide the fact that a library is made with TailBite.

What I think is that released libraries made with TailBite should include the pb source. It's very easy to screw up things if you don't do the correct things in your lib. But I can't force anyone to do this.

I agree in that PureBasic creates good ASM code, but nothing can beat good optimized ASM. But, of course, it takes some learning to code good optimized ASM ;)

I hope you enjoy this software. I use it a lot (and no, my libs aren't written in PB)

Documentation? Help?

Posted: Tue Mar 09, 2004 6:19 pm
by Iria
Hi,

Just wondered if any documentation was in the pipeline for TailBite?

Specifically the rules arounds lib construction, for example:

1) Where do I declare variables, inside the procedures outside?
2) Where do I do declares, strucutrues, enumerations
3) I guess a tutorial would sort most of these issues out
4) Are the lib procedure variable argument names used as the Japbe in editor help (at the bottom)...

Ive been through all your example code and it seems to me that I would write a lib exactly like I would write a DLL, is that simply the case? Or are there any rules I need to be aware of?

Other than that it seems to rock - well done!

:)

Posted: Tue Mar 09, 2004 7:17 pm
by Shannara
El_Choni, any chance of a Linux version?

Posted: Tue Mar 09, 2004 9:15 pm
by El_Choni
@Shannara: sorry, I don't even have Linux installed, my knowledge about Linux is very near 0. But anybody can try to port it, the core is mostly made of string operations.

@Iria:

1) Where do I declare variables, inside the procedures outside?

Like in PureBasic. Globals outside (declare, NOT use), shared and locals inside, etc.

2) Where do I do declares, strucutrues, enumerations

Wherever, like in PureBasic.

3) I guess a tutorial would sort most of these issues out

I wanted to avoid that... XD I must first finish the CGI and SQLite libs, we'll see then.

4) Are the lib procedure variable argument names used as the Japbe in editor help (at the bottom)...

I don't know. But here's a little example of a variable arguments function:

Code: Select all

ProdedureDLL MyFunction(arg1.s, arg2.f) ; This comment will be the PB IDE help line, don't know for japbe.
  ; Do whatever
EndProcedure

ProdedureDLL MyFunction2(arg1.s, arg2.f, arg3.b)
  ; Do whatever
EndProcedure

ProdedureDLL MyFunction3(arg1.s, arg2.f, arg3.b, arg4.s, arg5.l)
  ; Do whatever
EndProcedure
After TailBiting this, the PB IDE status bar will show:

Code: Select all

MyFunction(arg1.s, arg2.f, [arg3.b, [arg4.s, arg5.l]]) - This comment will be the PB IDE help line, don't know for japbe.
I hope this helps you. If there's anything I can do to make it more Japbe compatible, just tell me.
Ive been through all your example code and it seems to me that I would write a lib exactly like I would write a DLL, is that simply the case? Or are there any rules I need to be aware of?
It's all it the help file, but mostly, yes (but you don't use AttachProcess(), etc.)

Thanks

Posted: Tue Mar 09, 2004 9:53 pm
by Iria
That cleared up a lot of points :) thanks again and good luck with the CGI libs ! :)

Posted: Tue Mar 09, 2004 11:20 pm
by Andre
TailBite got its place now on www.PureArea.net :D

Posted: Wed Mar 10, 2004 5:40 am
by PB
> how does PB make it's ASM files? ... ah.. hand made.. by Fred.....
> I do not see how that argument works.. ?

Well, it's like this... let's say you want to make a birthday cake for a local
community baking contest. To win, it's better to bake everything yourself,
because the judges will know if it's not hand-made. So, you could either
buy all the ingredients and do it yourself (hand-written ASM), or you could
go to the shops and buy a frozen cake to thaw out and then stick the letters
on it that spell "Happy Birthday" from a cake accessory shop. This is like a
PureBasic-written library... the core ingredients are there, and to all intents
and purposes it's still an ASM source, but as you can see it's not the best
type of library to have if you're looking for speed, size and efficiency. ;)

Posted: Wed Mar 10, 2004 3:14 pm
by Ajm
What ?, have I missed a birthday !!! :D

Very nice analogy PB. ( Hit the nail right on the head )