[Embeddedml-developer] Fwd: problem with embedded ml
Brought to you by:
andrew36b
From: Andrew H. <and...@gm...> - 2009-11-29 21:08:35
|
---------- Forwarded message ---------- From: intw6 <int...@gm...> Date: Sun, Nov 29, 2009 at 3:32 PM Subject: Re: [Embeddedml-developer] problem with embedded ml To: Andrew Harris <and...@gm...> hi, that is no problem at all, thanks again On Sun, Nov 29, 2009 at 1:01 PM, Andrew Harris <and...@gm...> wrote: > > Would you mind if I forwarded our email discussion to the > embeddedml-developer list? That way others who searched for this > might be able to find the help too. > > -andrew > > On Sun, Nov 29, 2009 at 12:31 PM, Andrew Harris <and...@gm...> wrote: > > No problem. I am glad you got it working. Sorry for the extra work. > > Let me warn you that when you are writing ml programs, and you have a > > syntax error, the compiler is very terse, it doesn't even tell you a > > line number. This is quite annoying, but if you write small portions > > of code and compile as you go, you shouldn't have too many troubles. > > Note you don't have to run the program, just compile it. That way any > > syntax errors you have will be easier to track down. Feel free to > > email me with any questions. Other errors, such as type check > > failures are more descriptive. It's only in the early parsing stage > > that the errors aren't very useful. > > > > -andrew > > > > On Sun, Nov 29, 2009 at 12:25 PM, intw6 <int...@gm...> wrote: > >> hello, > >> after installing the new svn update > >> i installed libc6-dev-i386 for ubuntu x64 > >> everything works now. > >> thank you. > >> > >> > >> > >> > >> On Sun, Nov 29, 2009 at 10:59 AM, Andrew Harris <and...@gm...> > >> wrote: > >>> > >>> Hi intworld6, > >>> > >>> I believe I have fixed that. If you do an svn update in the root > >>> directory (where compile.sml) is, you should get the changes that > >>> support the cflags option. Alternatively, you can download the > >>> compiler again now and try it. The new "cflags" option is applied > >>> earlier, when each file is compiled. > >>> > >>> -andrew > >>> > >>> On Sun, Nov 29, 2009 at 10:55 AM, intw6 <int...@gm...> wrote: > >>> > hi, > >>> > > >>> > the -cflags option didn't exist (i downloaded the svn version of > >>> > embedded > >>> > ml), > >>> > > >>> > instead, i tried -compileflags "-m32" > >>> > > >>> > it looks that -m32 option is only applied towards the end, and not with > >>> > the > >>> > dependencies. > >>> > > >>> > ar: creating libarchive.a > >>> > ranlib libarchive.a > >>> > gcc -m32 -O2 -L. -larchive -o a.out > >>> > /usr/bin/ld: skipping incompatible ./libarchive.a when searching for > >>> > -larchive > >>> > /usr/bin/ld: cannot find -larchive > >>> > collect2: ld returned 1 exit status > >>> > make: *** [a.out] Error 1 > >>> > > >>> > > >>> > i can use 32-bit ubuntu running in virtual box while embedded ml is > >>> > upgraded > >>> > to 64-bit > >>> > > >>> > thanks! > >>> > > >>> > > >>> > > >>> > On Sun, Nov 29, 2009 at 10:33 AM, Andrew Harris <and...@gm...> > >>> > wrote: > >>> >> > >>> >> Hi intworld6, > >>> >> > >>> >> OK, I have modified the compiler slightly to make it easier to > >>> >> accept compiler flags. If you update svn and recompile the compiler, > >>> >> you should be able to use a new option on the compiler called "cflags" > >>> >> that will allow you to pass the -m32 option to the compiler when the C > >>> >> files are compiled. This should compile the code with 32-bit > >>> >> instructions. You can trying compiling sandmark.uml as follows: > >>> >> > >>> >> ../mlc.exe -cbackend sandmark.uml -cflags "-m32" > >>> >> > >>> >> and then just cd output/ and make as you did before. Let me know how > >>> >> it goes. Also if it doesn't work, please send me the output of the > >>> >> make. > >>> >> > >>> >> thanks, > >>> >> -andrew > >>> >> > >>> >> On Sun, Nov 29, 2009 at 10:11 AM, Andrew Harris <and...@gm...> > >>> >> wrote: > >>> >> > Hi intworld6, > >>> >> > > >>> >> > This is likely caused by gcc compiling 64-bit instructions. The > >>> >> > runtime for embeddedml currently requires 32-bit instructions. Give > >>> >> > me a bit to think of a good way to resolve this. > >>> >> > > >>> >> > -andrew > >>> >> > > >>> >> > On Sun, Nov 29, 2009 at 9:35 AM, intw6 <int...@gm...> wrote: > >>> >> >> hello, > >>> >> >> > >>> >> >> the sandmark example now compiles, > >>> >> >> but a.out gives a segmentation fault error. > >>> >> >> > >>> >> >> thank you > >>> >> >> > >>> >> >> > >>> >> >> On Sun, Nov 29, 2009 at 9:08 AM, Andrew Harris > >>> >> >> <and...@gm...> > >>> >> >> wrote: > >>> >> >>> > >>> >> >>> Hi intworld6, > >>> >> >>> > >>> >> >>> The first thing I would try would be to make sure there is no > >>> >> >>> output/ directory in the directory in which you're trying to > >>> >> >>> compile > >>> >> >>> sandmark.uml. Before trying the compilation, try deleting that > >>> >> >>> directory with rm -rf output/ > >>> >> >>> > >>> >> >>> The output/ directory is where the intermediate C files and > >>> >> >>> makefiles are stored. If that directory already exists, the > >>> >> >>> compilation will fail. Let me know if that doesn't help. And of > >>> >> >>> course, make sure to type that line carefully! > >>> >> >>> > >>> >> >>> -andrew > >>> >> >>> > >>> >> >>> On Sun, Nov 29, 2009 at 8:36 AM, intw6 <int...@gm...> wrote: > >>> >> >>> > hello, > >>> >> >>> > > >>> >> >>> > there is no additional output after "Compilation failed". > >>> >> >>> > > >>> >> >>> > thank you > >>> >> >>> > > >>> >> >>> > On Sun, Nov 29, 2009 at 7:46 AM, Andrew Harris > >>> >> >>> > <and...@gm...> > >>> >> >>> > wrote: > >>> >> >>> >> > >>> >> >>> >> Hi intworld6, is there any additional text that is output after > >>> >> >>> >> the > >>> >> >>> >> words > >>> >> >>> >> "Compilation failed.? > >>> >> >>> >> > >>> >> >>> >> thanks, > >>> >> >>> >> -andrew > >>> >> >>> >> > >>> >> >>> >> On Nov 28, 2009, at 3:52 PM, intw6 <int...@gm...> wrote: > >>> >> >>> >> > >>> >> >>> >>> hello, > >>> >> >>> >>> i am using ubuntu 9.04 amd64 and mlton to compile embeddedml > >>> >> >>> >>> it compiles with no problem, but i receive an error when > >>> >> >>> >>> attempting to > >>> >> >>> >>> run one of the tests > >>> >> >>> >>> > >>> >> >>> >>> following output: > >>> >> >>> >>> > >>> >> >>> >>> ../mlc.exe -cbackend sandmark.uml > >>> >> >>> >>> Parsing... > >>> >> >>> >>> Elaborating... > >>> >> >>> >>> Optimizing IL... > >>> >> >>> >>> (1387640) (122300) (46850) (33310) (18205) (18000) (17800) > >>> >> >>> >>> (14300) > >>> >> >>> >>> (14100) (12600) (7800) (7800) (7800) (7800) (7800) (7800) > >>> >> >>> >>> (7800) > >>> >> >>> >>> (7800) > >>> >> >>> >>> (7800) (7800) (7800) (7800) (5200) (0) > >>> >> >>> >>> CPS converting... > >>> >> >>> >>> Optimizing CPS... > >>> >> >>> >>> (infinite) (infinite) (10) (150) (0) > >>> >> >>> >>> Closure converting... > >>> >> >>> >>> Alloc converting... > >>> >> >>> >>> Backend conversion > >>> >> >>> >>> to C... > >>> >> >>> >>> Assembling... > >>> >> >>> >>> > >>> >> >>> >>> Compilation failed. > >>> >> >>> >>> |