1. Tests on ARM / Raspberry Pi

Forked from Re: OpenEuphoria on the raspberry pi

rkdavis said...

i've just run through the t_*.e tests in the tests directory, didn't do the t_net*.e or the t_c_*.e ones but only a few failures in

t_convert.e 
t_de_dep.e 
t_de_memory.e 
t_dep.e 
t_eutest.e 
t_text.e 
t_ifdef.e 
t_include_subdir.e 
t_locale.e 
t_memory.e 
a couple seem to be the same failure so it's looking good so far

The float80_to_atom() code is something I wrote that's designed to "manually" do the conversion based on the IEEE specs:

void arm_float80_to_float64( unsigned char *a, unsigned char *b ){ 
	int64_t exp_a, exp_b, sign; 
	int64_t mantissa_a, mantissa_b; 
 
	sign  = 0x80 == (a[9] & 0x80); 
	exp_a = (a[8] | ((a[9] & 0x7f) << 8 )) - 0x3fff; // IEEE854_LONG_DOUBLE_BIAS 
	// chop off most significant bit 
	mantissa_a = 0x7fffffffffffffffLL & *((int64_t*)a); 
 
	exp_b = (exp_a + 0x3ff ); // IEEE754_DOUBLE_BIAS 
	mantissa_b = (mantissa_a >> (11)); 
 
	*((int64_t*)b) = (mantissa_b & 0x7fffffffffffffLL) | (exp_b << 52)  | (sign << 63); 
} 

I used this (instead of just using a cast) in x86 and x86-64 interpreters, and running t_convert.e, I get:

$ ../64/eui t_convert.e 
  failed: float64_to_atom #1, expected: 157.82 but got: 157.82 
  failed: float80_to_atom #1, expected: 157.82 but got: -nan 
  failed: float80_to_atom #2, expected: inf but got: 8.29768153218589e+3395 
  failed: float80_to_atom #3, expected: -inf but got: 2.49092668478425e+3396 
  failed: to_number #27, expected: {0.121,0} but got: {0.121,0} 
  98 tests run, 93 passed, 5 failed, 95% success 
 
$ ../32/eui t_convert.e 
  failed: float80_to_atom #2, expected: inf but got: 1 
  failed: float80_to_atom #3, expected: -inf but got: -1 
  94 tests run, 92 passed, 2 failed, 98% success 
 

Some of the 64-bit failures are rounding errors. The main thing seems to be recognizing infinity. Are other float80 related tests failing for ARM?

Matt

new topic     » topic index » view message » categorize

2. Re: Tests on ARM / Raspberry Pi

just to let you all know i've announced a release of euphoria for the raspberry pi on the raspberry pi forums http://www.raspberrypi.org/phpBB3/viewtopic.php?p=292882#p292882

new topic     » goto parent     » topic index » view message » categorize

3. Re: Tests on ARM / Raspberry Pi

went through the tests agan and looks like a couple are non-issues. so this is an updated list of the tests that currently fail

t_convert.e -- float80_to_atom #2, #3 
t_dep.e  -- machine code in it 
t_eutest.e -- failed: eutest t_c_good_err_file.e, expected: 1 but got: 0, failed: eutest t_test_true.e, expected: 1 but got: 0 
t_text.e -- format 'AH' 
t_ifdef.e -- sizeof C_LONG LONG64 
t_include_subdir.e  ***** sometimes works e.g. if eui is in path but not run using ./ or ../../ ***** 
t_locale.e -- C locale 
t_memory.e --  poke_long, peek_longu 

new topic     » goto parent     » topic index » view message » categorize

4. Re: Tests on ARM / Raspberry Pi

rkdavis said...

went through the tests agan and looks like a couple are non-issues. so this is an updated list of the tests that currently fail

t_convert.e -- float80_to_atom #2, #3 
t_dep.e  -- machine code in it 
t_eutest.e -- failed: eutest t_c_good_err_file.e, expected: 1 but got: 0, failed: eutest t_test_true.e, expected: 1 but got: 0 
t_text.e -- format 'AH' 
t_ifdef.e -- sizeof C_LONG LONG64 
t_include_subdir.e  ***** sometimes works e.g. if eui is in path but not run using ./ or ../../ ***** 
t_locale.e -- C locale 
t_memory.e --  poke_long, peek_longu 

It looks like we were using LONG64 on ARM for some reason. Looks like it should be LONG32. I've just pushed an update that should fix t_ifdef and t_memory.

Matt

new topic     » goto parent     » topic index » view message » categorize

5. Re: Tests on ARM / Raspberry Pi

mattlewis said...
rkdavis said...

went through the tests agan and looks like a couple are non-issues. so this is an updated list of the tests that currently fail

t_convert.e -- float80_to_atom #2, #3 
t_dep.e  -- machine code in it 
t_eutest.e -- failed: eutest t_c_good_err_file.e, expected: 1 but got: 0, failed: eutest t_test_true.e, expected: 1 but got: 0 
t_text.e -- format 'AH' 
t_ifdef.e -- sizeof C_LONG LONG64 
t_include_subdir.e  ***** sometimes works e.g. if eui is in path but not run using ./ or ../../ ***** 
t_locale.e -- C locale 
t_memory.e --  poke_long, peek_longu 

It looks like we were using LONG64 on ARM for some reason. Looks like it should be LONG32. I've just pushed an update that should fix t_ifdef and t_memory.

Matt

ok i'll pull that in a few minutes then. I think the t_locale.e thing is how my raspberry pi is setup, i'll have a twiddle with locales and see. I think t_include_subdir.e is actually the expected behaviour? (i really need to install euphoria in a vm or on the desktop sometime ) so just a couple left to workout what is going on

new topic     » goto parent     » topic index » view message » categorize

6. Re: Tests on ARM / Raspberry Pi

rkdavis said...
mattlewis said...
rkdavis said...

went through the tests agan and looks like a couple are non-issues. so this is an updated list of the tests that currently fail

t_include_subdir.e  ***** sometimes works e.g. if eui is in path but not run using ./ or ../../ ***** 

It looks like we were using LONG64 on ARM for some reason. Looks like it should be LONG32. I've just pushed an update that should fix t_ifdef and t_memory.

Matt

ok i'll pull that in a few minutes then. I think the t_locale.e thing is how my raspberry pi is setup, i'll have a twiddle with locales and see. I think t_include_subdir.e is actually the expected behaviour? (i really need to install euphoria in a vm or on the desktop sometime ) so just a couple left to workout what is going on

The t_include_subdir.e sounds like we could add some checking, and maybe canonicalize the path or something. But I agree with your diagnosis.

Matt

new topic     » goto parent     » topic index » view message » categorize

7. Re: Tests on ARM / Raspberry Pi

t_ifdef.e & t_memory.e now both pass

new topic     » goto parent     » topic index » view message » categorize

8. Re: Tests on ARM / Raspberry Pi

Here is another data point on my Cortex-A8 ARM board:

eui -v 
Euphoria Interpreter  v4.1.0 development 
   32-bit Linux, Using System Memory 
   Revision Date: 2013-02-20 20:56:20, Id: 5991:3b50eb52262b 
 
  Failed: bin -test bench.ex (0.090000) expected 0 got 256 
  Failed: bin -test bugreport.ex (0.090000) expected 0 got 256 
  Failed: bin -test buildcpdb.ex (0.080000) expected 0 got 256 
  Failed: bin -test ed.ex (0.090000) expected 0 got 256 
  Failed: bin -test eucoverage.ex (0.080000) expected 0 got 256 
  Failed: bin -test euloc.ex (0.090000) expected 0 got 256 
  Failed: Value test for C_INT #2 (0.000000) expected -2000000000 got 0 
  Failed: Value test for C_LONGLONG #2 (0.010000) expected -2199023255552 got 0 
  Failed: Can call and things are passed correctly for ten argument functions (0.000000) expected 1.12589993095027e+15 got 1.12589991858202e+15 
  Failed: Testing passing eight doubles only (0.000000) expected 0 got 10430452.265625 
  Failed: Testing passing eight doubles only and two long long ints (0.000000) expected -0.692138671875 got 0 
  Failed: float80_to_atom #1 (0.000000) expected 157.82 got 3.70433943767225e-314 
  Failed: float80_to_atom #2 (0.000000) expected inf got 3.70433943767225e-314 
  Failed: float80_to_atom #3 (0.000000) expected -inf got 3.70433943767225e-314 
  Failed: Is memory allocated by allocate_code() executable? (0.010000) expected 1 got 0 
  Failed: Is memory allocated by allocate_code() executable? (0.010000) expected 1 got 0 
  Failed: eutest t_test_true.e (0.070000) expected 1 got 0 
  Failed: eutest t_c_good_err_file.e (0.070000) expected 1 got 0 
  Failed: canonical_path() #11 (0.000000) expected "/home/user/Code/Euphoria/tests/" got "/home/user/Code/euphoria/tests/" 
  Failed: Seek STDOUT (0.000000) expected 1 got 0 
  Failed: money (0.000000) expected "$1,020.50" got "$0.00" 
  Failed: number (0.000000) expected "1,020.50" got "0.00" 
  Failed: integer (0.000000) expected "1,020" got "0" 
  Failed: number (0.000000) expected "1,020.10" got "0.00" 
  Failed: large integer (0.000000) expected "9,999,999,999,999" got "0" 
  Failed: deserialize f80 (0.000000) expected {1.3,16} got {3.70300177667503e-314,16} 
  Failed: deserialize file long double (0.010000) expected 1.3 got 1 
  Failed: connect to server (1.010000) expected 1 got 0 
  Failed: Encoding #3 (0.010000) expected "Windows 1251 (Cyrillic)" got "ASCII" 
  Failed: Encoding uppercase #4 (0.010000) expected {128,129,138,140,141,142,143,161,163,165,168,170,175,178,189, 
  Failed: Encoding #5 (0.010000) expected "OEM 737 (Greek)" got "ASCII" 
  Failed: Encoding uppercase #6 (0.000000) expected {128,129,130,131,132,133,134,135,136,137,138,139,140,141,142, 
  Failed: format 'AH' (0.000000) expected "11111111111111111111111101001111" got "-177" 

Thanks,
Ira

new topic     » goto parent     » topic index » view message » categorize

9. Re: Tests on ARM / Raspberry Pi

a full testeu http://pastebin.com/tDKaPTfA

new topic     » goto parent     » topic index » view message » categorize

10. Re: Tests on ARM / Raspberry Pi

RKD: Here is a test for you using Euphoria!

http://www.raspberrypi.org/archives/3334
Forked into: Ubuntu on tabets

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu