Shop OBEX P1 Docs P2 Docs Learn Events
How much would YOU pay for a Spin compiler? — Parallax Forums

How much would YOU pay for a Spin compiler?

mparkmpark Posts: 1,305
edited 2008-09-04 00:48 in Propeller 1
Would anyone pay anything for a Spin compiler that came with source code (C#)?


Yours Curiously,

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Michael Park

PS, BTW, and FYI:
To search the forum, use search.parallax.com (do not use the Search button).
Check out the Propeller Wiki: propeller.wikispaces.com/

Comments

  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-08-30 23:53
    Pretty sure this isn't exactly what you are asking, but I'd contribute
    $50-$100 bounty on a .spin compiler that ran on the propeller.

    OBC

    mpark said...
    Would anyone pay anything for a Spin compiler that came with source code (C#)?


    Yours Curiously,
    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • Timothy D. SwieterTimothy D. Swieter Posts: 1,613
    edited 2008-08-31 02:12
    Oh.....the bounty idea for a Spin compiler.....a community becomes dangerous when bounties are placed and other collect. I hope someone can go for it.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Timothy D. Swieter, E.I.

    www.brilldea.com·- Prop Blade, LED Painter, RGB LEDs, uOLED-IOC, eProto fo SunSPOT, BitScope
    www.sxmicro.com - a blog·exploring the SX micro
    www.tdswieter.com
  • hippyhippy Posts: 1,981
    edited 2008-08-31 04:27
    mpark said...
    Would anyone pay anything for a Spin compiler that came with source code (C#)?

    Probably not, but it's possible. Having source or not wouldn't swing the decision.

    It would be a hard sell, but what could convince me is ...

    * Command line compiler plus IDE ( with command line compiler not switching to windows to ask me a question or to tell me something )

    * Runs under Win98SE with good speed on a 1GHz CPU ( .Net 2.0 is generally okay )

    * Supports #Define ( single and multi-line ), #Include, #If-Else-EndIf etc

    * Allows PASM EQU ( "Fred EQU $1FF", or "Fred ORG $1FF" ) and doesn't complain when the address is over $1EF

    * Supports templates or some mechanism for assembling LMM code which is in a user defined format

    * Generates a symbol table in text format

    * Generates a disassembed bytecode listing so we can verify your code generation easily

    * Allows the inclusion of a custom Spin Interpreter kernel ( that's easy, can provide details )

    It's probably also worth checking out -
    propeller.wikispaces.com/Propeller+Tool+-+Enhancement+Requests
  • BradCBradC Posts: 2,601
    edited 2008-08-31 06:28
    Not interested in a compiler that is not cross platform.. and using a VM like Java or C# is just not interesting to me at all...
    Source code or no...

    If it does not run on OSX Intel and PPC, Linux x86-32 and X86-64 and old versions of windows it just won't fill the gap any more than the current parallax compiler and a VM..

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Pull my finger!
  • ColeyColey Posts: 1,110
    edited 2008-08-31 09:42
    Gosh! Aren't people demanding!!! lol

    @mpark

    Do you mean a SPIN bytecode compiler or SPIN to ASM compiler?

    Regards,

    Coley

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    PropGFX Forums - The home of the Hybrid Development System and PropGFX Lite
  • heaterheater Posts: 3,370
    edited 2008-08-31 12:54
    Coley said...
    Gosh! Aren't people demanding!!! lol

    Not really so demanding. If you have the skills to write a compiler in Java or C# you could probably do it in C++ just as easily. Or just plain C.
    Its very easy to write command line programs that are cross platform in C++ or C (Only has to read and write files after all).
    So if your source is available it's can just be recompiled for any new platform.
    This makes the need for all the bloat and hassle a Java or C# VM go away.

    As for what I would pay, well, nothing. If it's tied to the Windows platform and C# you would probably have to pay me to take it away.

    Why:
    1) I already have a Spin compiler for free.
    2) That compiler already causes me the pain of having to use Windows or an emulator/VM under my preferred OS.
    3) I prefer languages to not use indentation for syntax.
    4) Might be interested in something that compiled Spin to LMM and was compatible/linkable with ImageCraft C.
    5) But then why not just use C ?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    For me, the past is not over yet.
  • hippyhippy Posts: 1,981
    edited 2008-08-31 13:47
    Perhaps the question needs rephrasing to get a more positive response ... ?

    Q1) Would you like a Spin compiler ?

    Yes.
    Maybe - if it runs on my OS.
    No.

    Q2) Would you pay for it ?

    Yes.
    Maybe - Depends how much
    Perhaps - If it's worth it.
    No - I'll wait for the free Bit Torrent version.
    No - I'm not interested.

    For me (Q1) Yes, (Q2) No.
  • JT CookJT Cook Posts: 487
    edited 2008-08-31 15:47
    I guess I am a little confused too on what is meant by pay. Did you mean pay as in purchase or pay as in donate/bounty?

    I think what is needed is a compiler written in C that can be ported to different platforms. Also it is hard to sell something 3rd party when the original one is free (even if it is closed source).
  • waltcwaltc Posts: 158
    edited 2008-08-31 17:19
    Check with Parallax first, you don't want to end up in court.

    But to answer your question, no. I use Spin but don't like it one bit. Its the only other language besides Java that makes me like C.

    However you need to consider that its a proprietary language tied to a one of kind processor. Your market is going to be small at best and you'll never recoup your time and money. Just ask ImageCraft if doing C for the Prop was a money maker.

    IMO you might want to consider doing a BASIC compiler with Prop extensions(not Pbasic), that generates native code. It would be a great entry point for people to try out the Prop and not have to learn a rather odd and proprietary language in order to do it.

    As far as source code goes, C or Pascal. I wouldn't touch anything that used Java or C#.
    FWIW
  • BradCBradC Posts: 2,601
    edited 2008-08-31 17:38
    hippy said...
    [noparse][[/noparse]
    * Generates a symbol table in text format

    * Generates a disassembed bytecode listing so we can verify your code generation easily

    Something along these lines?

    Writing Object Table at 1
    PUB AAA3(X1, X2) : Result | X3, X4[noparse][[/noparse]400], X5, X6
                            X1 := (X4)
    Addr : 0018:             70  - (X4) READ DBASE Long Variable offset 4 
    Addr : 0019:             65  - (X1) WRITE DBASE Long Variable offset 1 
                            INA := 1
    Addr : 001A:             36  - Constant 1 (00000001)
    Addr : 001B:          3F B2  - (INA) WRITE Long Register  2 
                            Long[noparse][[/noparse]$12345678] += 2 + 2
    Addr : 001D:          37 00  - Constant 2 (00000002)
    Addr : 001F:          37 00  - Constant 2 (00000002)
    Addr : 0021:             EC  - +
    Addr : 0022: 3B 12 34 56 78  - Constant $12345678 (12345678)
    Addr : 0027:             36  - Constant 1 (00000001)
    Addr : 0028:          D2 4C  - (Long) ASSIGN Absolute Long POP Address POP Index   MATHOP +
                            --INA
    Addr : 002A:       3F D2 36  - (INA) ASSIGN Long Register  2 --PRE
                            INA++
    Addr : 002D:       3F D2 2E  - (INA) ASSIGN Long Register  2 POST++
                            INA~
    Addr : 0030:       3F D2 18  - (INA) ASSIGN Long Register  2 POST~
                            INA~~
    Addr : 0033:       3F D2 1C  - (INA) ASSIGN Long Register  2 POST~~
                            IF 1
    Addr : 0036:             36  - Constant 1 (00000001)
    Addr : 0037:          0A 05  - JZ Label0001
                              X1 := 1
    Addr : 0039:             36  - Constant 1 (00000001)
    Addr : 003A:             65  - (X1) WRITE DBASE Long Variable offset 1 
    Addr : 003B:       04 80 52  - JMP Label0002
    Addr : 003E:                 - Label0001
                            ELSEIF 2
    Addr : 003E:          37 00  - Constant 2 (00000002)
    Addr : 0040:          0A 0D  - JZ Label0003
                              IF 16
    Addr : 0042:          37 03  - Constant 16 (00000010)
    Addr : 0044:          0A 03  - JZ Label0004
                                X1 := 16
    Addr : 0046:          37 03  - Constant 16 (00000010)
    Addr : 0048:             65  - (X1) WRITE DBASE Long Variable offset 1 
    Addr : 0049:                 - Label0004
    Addr : 0049:                 - Label0005
                              X1 := 2
    Addr : 0049:          37 00  - Constant 2 (00000002)
    Addr : 004B:             65  - (X1) WRITE DBASE Long Variable offset 1 
    Addr : 004C:       04 80 41  - JMP Label0002
    Addr : 004F:                 - Label0003
                            ELSEIFNOT 3 + (6 + 4 - -25 / 24) + (X4)
    Addr : 004F:          37 21  - Constant 3 (00000003)
    Addr : 0051:          38 06  - Constant 6 (00000006)
    Addr : 0053:          37 01  - Constant 4 (00000004)
    Addr : 0055:             EC  - +
    Addr : 0056:       38 18 E7  - Constant 25 (FFFFFFE8)
    Addr : 0059:          38 18  - Constant 24 (00000018)
    Addr : 005B:             F6  - /
    Addr : 005C:             ED  - -
    Addr : 005D:             EC  - +
    Addr : 005E:             70  - (X4) READ DBASE Long Variable offset 4 
    Addr : 005F:             EC  - +
    Addr : 0060:          0B 04  - JNZ Label0006
                              X1 := X2
    Addr : 0062:             68  - (X2) READ DBASE Long Variable offset 2 
    Addr : 0063:             65  - (X1) WRITE DBASE Long Variable offset 1 
    Addr : 0064:          04 2A  - JMP Label0002
    Addr : 0066:                 - Label0006
                            ELSEIF X1 //= 24 - X2 + (X1 + $321 / -24 + 6 - -X3) / X4[noparse][[/noparse]X5] + ^^ X6
    Addr : 0066:          38 18  - Constant 24 (00000018)
    Addr : 0068:             68  - (X2) READ DBASE Long Variable offset 2 
    Addr : 0069:             ED  - -
    Addr : 006A:             64  - (X1) READ DBASE Long Variable offset 1 
    Addr : 006B:       39 03 21  - Constant $321 (00000321)
    Addr : 006E:       38 17 E7  - Constant 24 (FFFFFFE9)
    Addr : 0071:             F6  - /
    Addr : 0072:             EC  - +
    Addr : 0073:          38 06  - Constant 6 (00000006)
    Addr : 0075:             EC  - +
    Addr : 0076:             6C  - (X3) READ DBASE Long Variable offset 3 
    Addr : 0077:             E6  - -
    Addr : 0078:             ED  - -
    Addr : 0079:       CC 86 50  - (X5) READ DBASE Long Memory Address 0650 
    Addr : 007C:          DC 10  - (X4) READ DBASE Long POP Index Memory Address 0010 
    Addr : 007E:             F6  - /
    Addr : 007F:             EC  - +
    Addr : 0080:       CC 86 54  - (X6) READ DBASE Long Memory Address 0654 
    Addr : 0083:             F8  - ^^
    Addr : 0084:             EC  - +
    Addr : 0085:          66 D7  - (X1) ASSIGN PUSH DBASE Long Variable offset 1  MATHOP //
    Addr : 0087:          0A 05  - JZ Label0007
                                X3 := 4  
    Addr : 0089:          37 01  - Constant 4 (00000004)
    Addr : 008B:             6D  - (X3) WRITE DBASE Long Variable offset 3 
    Addr : 008C:          04 02  - JMP Label0002
    Addr : 008E:                 - Label0007
                              X1 := X2
    Addr : 008E:             68  - (X2) READ DBASE Long Variable offset 2 
    Addr : 008F:             65  - (X1) WRITE DBASE Long Variable offset 1 
    Addr : 0090:                 - Label0008
    Addr : 0090:                 - Label0002
                            --X4[noparse][[/noparse]55]
    Addr : 0090:          38 37  - Constant 55 (00000037)
    Addr : 0092:       DE 10 36  - (X4) ASSIGN DBASE Long POP Index Memory Address 0010 --PRE
                            X5 := ~~X4[noparse][[/noparse]70]
    Addr : 0095:          38 46  - Constant 70 (00000046)
    Addr : 0097:       DE 10 94  - (X4) ASSIGN PUSH DBASE Long POP Index Memory Address 0010 ~~PRE
    Addr : 009A:       CD 86 50  - (X5) WRITE DBASE Long Memory Address 0650 
                            X6 := 3
    Addr : 009D:          37 21  - Constant 3 (00000003)
    Addr : 009F:       CD 86 54  - (X6) WRITE DBASE Long Memory Address 0654 
    Addr : 00A2:             32  - Return
    
    

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Pull my finger!
  • hippyhippy Posts: 1,981
    edited 2008-08-31 18:17
    That's the spirit, and I'm impressed ...

    Addr : 006E: 38 17 E7 - Constant 24 (FFFFFFE9)

    Looks like a missing "-", and the FFFFFFE9 should be FFFFFFE8 - And as I'm trying to get LCC working that really isn't a complaint, just a comment !

    Just for comparison, here's my disassembly of the X1 //= line at 0066 ...

    0018         38 18                    PUSH     #$18
    001A         68                       PUSH     LOC+8
    001B         ED                       SUB
    001C         64                       PUSH     LOC+4
    001D         39 03 21                 PUSH     #801
    0020         38 17                    PUSH     #23
    0022         E7                       BIT_NOT
    0023         F6                       DIV
    0024         EC                       ADD
    0025         38 06                    PUSH     #6
    0027         EC                       ADD
    0028         6C                       PUSH     LOC+12
    0029         E6                       NEG
    002A         ED                       SUB
    002B         CC 86 50                 PUSH     LOC+1616
    002E         DC 10                    PUSH     LOC+16[noparse][[/noparse]]
    0030         F6                       DIV
    0031         EC                       ADD
    0032         CC 86 54                 PUSH     LOC+1620
    0035         F8                       SQRT
    0036         EC                       ADD
    0037         66 57                    USING    LOC+4 MOD
    
    
  • jazzedjazzed Posts: 11,803
    edited 2008-08-31 18:48
    BradC, Where are you going with this?
    I assume that listing was generated by a program. You are one step away from providing spin source/bytecode line translation. No? I guess accomodating everyone's style in the lookup could prove difficult.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    --Steve
  • BradCBradC Posts: 2,601
    edited 2008-08-31 21:06
    It's a little toy I've been working away on in the background [noparse]:)[/noparse] (also why the USB stuff has come to a grinding halt lately)

    Anything after the assembly code might well be slightly incorrect as I alter a lot of stuff in pre-processing. I've probably forgotten to change the descriptor on the token when I've done a unary negate. My benchmark is a bit for bit binary compatibility with the parallax compiler.. and that it does..

    No, it's not finished..

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Pull my finger!
  • BradCBradC Posts: 2,601
    edited 2008-08-31 21:26
    hippy said...
    That's the spirit, and I'm impressed ...

    Addr : 006E: 38 17 E7 - Constant 24 (FFFFFFE9)

    Looks like a missing "-", and the FFFFFFE9 should be FFFFFFE8 - And as I'm trying to get LCC working that really isn't a complaint, just a comment !

    Just for comparison, here's my disassembly of the X1 //= line at 0066 ...

    0020 38 17 PUSH #23
    0022 E7 BIT_NOT

    [noparse][[/noparse]/code]

    If you look closely, you will see the bytecode is identical.. It's my description that sucks.
    What I've done is taken a constant and negated it. I've absorbed the unary '-' into the constants bytecode, so in the disassembly listing you wont see the '!', but it's there tacked on the end of the constant. Like I said, the stuff in the list you saw is kinda nasty internal debugging output rather than a decent list.. I'll need to fix that.. I'm pretty sure I know how to make it work effectively.

    I've done a binary diff and the bytecode is identical, so I win there [noparse]:)[/noparse]

    If you look at my disassembler output, you see pretty much what yours gives
    (Ignore the addresses, I've added stuff to the top of the method since then)

    0:1 : 009A : Variable Operation Local Offset - 1 Read
    0:1 : 009B : Constant 2 Bytes - 03 21 
    0:1 : 009E : Constant 1 Bytes - 17 
    0:1 : 00A0 : Math Op !
    0:1 : 00A1 : Math Op /
    
    

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Pull my finger!
  • dazed&confuseddazed&confused Posts: 20
    edited 2008-09-02 12:46
    I wouldn't give you a penny for a Spin compiler;However A BASIC$ compiler!!!! w/ the speed of Spin/ASM, I'd go a $100.ASM sucks and Spin isn't much better.After 27 years of prog. in Basic$ its hard to throw it out and start something else.
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-09-02 14:14
    At risk of hijacking this thread, (again, sorry!)

    PropII should be able to run FemtoBASIC at 10x the current speed with many
    times more memory. You'll get your wish soon..
    (At least by present standards.)

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • rjo_rjo_ Posts: 1,825
    edited 2008-09-03 04:27
    If it is money and programming that interests you... that's a pretty good start.

    In terms of problems I would like to see solved... it could all be done in a pre-compiler or Chip is planning to do it anyway.
    Here is a problem that is so mundane that I don't think Chip will ever waste his time on it, but someone should.

    Let's say that I have a choice of graphics devices... LCDs, TV, uoleds, etc etc... and I want to make a product and when I get all done I change my mind... what do I have to do?

    It certainly isn't go to my pre-compiler and change a check box is it?

    And that is just one of the many things options that a designer has to consider.

    The market is about a year away, you guys have plenty of time to do it. How about a committee?


    Rich
  • BradCBradC Posts: 2,601
    edited 2008-09-03 06:27
    I think that puce is a lovely colour for the back of the bikeshed

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Pull my finger!
  • AribaAriba Posts: 2,687
    edited 2008-09-04 00:48
    rio_

    What you want is a Preprocessor. For that exists minimal 2 ready to use solutions:
    My PreSpin: http://forums.parallax.com/showthread.php?p=655470
    but you need version 0.2 from: www.insonix.ch/propeller/prespin.html

    and Epmoyer's ScUMM: http://forums.parallax.com/showthread.php?p=654555

    BTW: don't think you can make money with such Tools for the Propeller. PropTerminal, PreSpin and PASD have been downloaded hunderts of times, but not one donation, so far. shakehead.gif

    Andy
Sign In or Register to comment.