You need to do:
touch null.c
g++ -dM -E null.c
and see what __ARCH_ARM_xxx__ macro your gcc compiler defines. Then
you need to add that to src/arm/macro-assembler-arm.cc. I am adding
__ARM_ARCH_6__ to it today so perhaps that solves your problem.
Depending on the gcc version you are using you may need the following
patch. The -fno-strict-aliasing flag is because of a bug in V8, and
the -fno-tree-sink option is because of a bug in gcc-4.4.1 (gets
around an error where you get a 'pure virtual called' crash as soon as
you start up the VM).
Index: SConstruct
===================================================================
--- SConstruct (revision 2819)
+++ SConstruct (working copy)
@@ -48,9 +48,9 @@
# and avoid dtoa.c strict aliasing issues
if os.environ.get('GCC_VERSION') == '44':
GCC_EXTRA_CCFLAGS = ['-fno-tree-vrp']
- GCC_DTOA_EXTRA_CCFLAGS = ['-fno-strict-aliasing']
+ GCC_DTOA_EXTRA_CCFLAGS = ['-fno-strict-aliasing', '-fno-tree-sink']
else:
- GCC_EXTRA_CCFLAGS = []
+ GCC_EXTRA_CCFLAGS = ['-fno-strict-aliasing', '-fno-tree-sink']
GCC_DTOA_EXTRA_CCFLAGS = []
ANDROID_FLAGS = ['-march=armv5te',
2009/9/8 Rames <[email protected]>:
>
> I think I went a little further understanding my issue:
> After commenting the cpu-arm.cc line 123 asm volatile("bkpt 0");
> to get rid of this unknown instruction I get the following error:
>
> src/arm/macro-assembler-arm.cc:62:2: error: #error "for thumb inter-
> working we require architecture v5t or above
> scons: *** [obj/release/arm/macro-assembler-arm.o] Error 1
>
> So it seems that no correct __ARM_ARCH_XX__ macro is defined
> (assembler-arm.cc line 57), meaning that my architecture does not
> fit.
> But I guess cortex A8 arms are compatible with previous arm
> versions. Is there any way to get my beagleboard to compile v8?
>
> On Sep 8, 1:39 pm, "A.Rames" <[email protected]> wrote:
>> I am trying to compile v8 shell example on my beagleboard, but the
>> build meets fails ont the following error:
>>
>> g++ -o obj/release/arm/cpu-arm.o -c -Wall -Werror -W -Wno-unused-
>> parameter -Wnon-virtual-dtor -pedantic -O3 -fomit-frame-pointer -fdata-
>> sections -ffunction-sections -ansi -fno-rtti -fno-exceptions -Wall -
>> Werror -W -Wno-unused-parameter -Wnon-virtual-dtor -pedantic -O3 -
>> fomit-frame-pointer -fdata-sections -ffunction-sections -ansi -
>> DV8_TARGET_ARCH_ARM -DV8_NATIVE_REGEXP -DENABLE_LOGGING_AND_PROFILING -
>> Isrc src/arm/cpu-arm.cc
>>
>> /tmp/ccMqAVAn.s: Assembler messages:
>> /tmp/ccMqAVAn.s:58: Error: selected processor does not support `bkpt
>> 0'
>>
>> I actually managed to get v8 javascript shell work by cross-compiling
>> it with the CodeSourcery toolchain, but I would like to compile it on
>> the board itself as the cross-compiled shell seems not very efficient:
>> I get a score around 93 on the v8 version 3 test. This seems quite low
>> compared to the 800 score on a 300MHz faster x86 intel processor, and
>> compared to SFX without JIT on the same board ( "only" 45% slower
>> whereas it's about 5 times slower on other processors)
>>
>> I am not very skilled about arm architectures and how v8 supports
>> them, but reading through the code I noticed there is no
>> __ARM_ARCH_8__ test like for other arm architectures in macro-
>> assembler-arm.cc l.57. Is the arm 8 architecture not supported?
>>
>> Could someone either help me fix this error or confirm (or infirm)
>> those weird results?
>>
>> Thanks
> >
>
--
Erik Corry, Software Engineer
Google Denmark ApS. CVR nr. 28 86 69 84
c/o Philip & Partners, 7 Vognmagergade, P.O. Box 2227, DK-1018
Copenhagen K, Denmark.
--~--~---------~--~----~------------~-------~--~----~
v8-users mailing list
[email protected]
http://groups.google.com/group/v8-users
-~----------~----~----~----~------~----~------~--~---