[Vm-dev] Building StackVM on ARM linux meego-hartmann

Denis Kudriashov dionisiydk at gmail.com
Wed Oct 3 18:31:16 UTC 2012


Ok, I just remove keys from makefilelist. And now I have error* no high res
clock defined:*

sqLong
ioHighResClock(void)
{
  /* return the value of the high performance counter */
  sqLong value = 0;
#if defined(__GNUC__) && ( defined(i386) || defined(__i386) ||
defined(__i386__)  \
            || defined(i486) || defined(__i486) || defined (__i486__) \
            || defined(intel) || defined(x86) || defined(i86pc) )
    __asm__ __volatile__ ("rdtsc" : "=A"(value));
#else
*# error "no high res clock defined"*
#endif
  return value;
}

I try to just return value here;

2012/10/3 Denis Kudriashov <dionisiydk at gmail.com>

> I was incorrect. Problem happens early on defining atomic access of 64-bit
> variables.
> So I just uncomment something like this:
>
> /* Dear implementor, you have choices.  For example consider defining
> get64 &
>  * set64 thusly
>  * #define get64(var) read64(&(var))
>  * #define set64(var,val) write64(&(var),val)
>  * and get the JIT to generate read64 & write64 above atomic 64-bit
> read/write.
>  */
> *# define get64(var) read64(&(var))
> # define set64(var,val) write64(&(var),val)
> *
> //error atomic access of 64-bit variables not yet defined for this platform
> # endif
> -------------------------------------
>
> Now I have another problem:
>
> [ 90%] Building C object
> CMakeFiles/StackVM.dir/cogVM/blessed/platforms/unix/vm/sqUnixHeartbeat.c.o
> cc1: error: incorrect key "-mno-rtd"
> cc1: error: incorrect key "-mno-accumulate-outgoing-args"
> make[2]: ***
> [CMakeFiles/StackVM.dir/cogVM/blessed/platforms/unix/vm/sqUnixHeartbeat.c.o]
> error 1
>
> make[1]: *** [CMakeFiles/StackVM.dir/all] error 2
> make: *** [all] error 2
>
> What this keys mean? And what I can do?
>
>
>
>
> 2012/10/3 Denis Kudriashov <dionisiydk at gmail.com>
>
>> I found comment:
>>
>> /* Atomic increment of 32-bit values allows a lock-free implementation of
>> the
>>  * request side of signalSemaphoreWithIndex:
>>  */
>>
>>     /* Currently we provide definitions for x86 and GCC only.  */
>> #if defined(__GNUC__) && (defined(i386) || defined(__i386) ||
>> defined(__i386__) || defined(_X86_))
>> #ifdef TARGET_OS_IS_IPHONE
>> #define sqAtomicAddConst(var,n) OSAtomicAdd32(n,&var)
>> #else
>> # define sqAtomicAddConst(var,n) \
>>     asm volatile ("lock addl %1, %0" : "=m" (var) : "i" (n), "m" (var))
>> #endif
>> #else
>> #ifdef TARGET_OS_IS_IPHONE
>> #define sqAtomicAddConst(var,n) OSAtomicAdd32(n,&var)
>> #endif
>> /* Dear implementor, you have choices.  Google atomic increment and you
>> will
>>  * find a number of implementations for other architectures.
>>  */
>> #endif
>>
>> I now try to google it.
>> Maybe you already know how to fix it?
>>
>>
>> 2012/10/3 Denis Kudriashov <dionisiydk at gmail.com>
>>
>>> Ok. I exclude IA32ABIPlugin. It's help. And now I have next problem:
>>>
>>> [ 87%] Building C object
>>> CMakeFiles/StackVM.dir/cogVM/blessed/platforms/Cross/vm/sqTicker.c.o
>>> In file included from /cogVM/blessed/platforms/Cross/vm/sqTicker.c:56:
>>> /cogVM/blessed/platforms/Cross/vm/sqAtomicOps.h:140: ошибка: #error
>>> atomic access of 64-bit variables not yet defined for this platform
>>> make[2]: ***
>>> [CMakeFiles/StackVM.dir/cogVM/blessed/platforms/Cross/vm/sqTicker.c.o]
>>> error 1
>>> make[1]: *** [CMakeFiles/StackVM.dir/all] error 2
>>> make: *** [all] error 2
>>>
>>>
>>> What I can do now?
>>>
>>>
>>> 2012/10/3 David T. Lewis <lewis at mail.msen.com>
>>>
>>>
>>>> On Wed, Oct 03, 2012 at 10:31:55AM +0200, Igor Stasenko wrote:
>>>> >
>>>> > On 3 October 2012 06:29, Denis Kudriashov <dionisiydk at gmail.com>
>>>> wrote:
>>>> > >
>>>> > > Great. I remove it.
>>>> > > Now process stopped at ~30% on:
>>>> > >
>>>> > > tmp/cc33Ks89.s: Assembler messages:
>>>> > > /tmp/cc33Ks89.s:90: Error: ARM register expected -- `mov
>>>> [sp,#844],%edx'
>>>> > > /tmp/cc33Ks89.s:118: Error: bad instruction `fldl [r0,#0]'
>>>> > > make[2]: ***
>>>> [IA32ABI/CMakeFiles/IA32ABI.dir/cogVM/blessed/platforms/Cross/plugins/IA32ABI/ia32abicc.c.o]
>>>> > > ???????????? 1
>>>> >
>>>> > so remove that plugin from a build.
>>>> > You should start from minimum set of plugins and then proceed adding
>>>> > more once you can make them compiling/working.
>>>> >
>>>>
>>>> FYI, the smallest useable VM requires these plugins:
>>>>
>>>>   BitBltSimulation
>>>>   BalloonEnginePlugin
>>>>   FilePlugin
>>>>
>>>> But usually you will also want networking, so a good starting point for
>>>> a minimal VM is:
>>>>
>>>>   BitBltSimulation
>>>>   BalloonEnginePlugin
>>>>   FilePlugin
>>>>   SocketPlugin
>>>>
>>>> Dave
>>>>
>>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20121003/e129e338/attachment.htm


More information about the Vm-dev mailing list