Skip to content

Resolve vec4 : glm_vec4_distance() to satisfy compiling on armv7#84

Merged
recp merged 5 commits intorecp:masterfrom
haxpor:fix_82
Apr 27, 2019
Merged

Resolve vec4 : glm_vec4_distance() to satisfy compiling on armv7#84
recp merged 5 commits intorecp:masterfrom
haxpor:fix_82

Conversation

@haxpor
Copy link
Copy Markdown
Contributor

@haxpor haxpor commented Apr 18, 2019

Fixed according to @recp 's suggestion of solution at #82 .
Test cases are added.

Tested on PC (Linux ubuntu 18.04 with SSE/SSE2/SSE3/SSE4 capable).
Tested on real Android device (Android 6.0, aarch64).

haxpor added 3 commits April 19, 2019 01:47
Before it used armv8 only function thus it leads to build failed for
Android with target of armv7 i.e. armeabi-v7a. This fixed that issue.
@haxpor
Copy link
Copy Markdown
Contributor Author

haxpor commented Apr 18, 2019

note I noticed 1 failed test result in bezier (pulled from the tip).

@recp
Copy link
Copy Markdown
Owner

recp commented Apr 20, 2019

Hi @haxpor

Thanks for this PR.

I have added this to travis:

after_failure:
  - cat ./test-suite.log

we should see what is wrong in travis's logs now

@recp
Copy link
Copy Markdown
Owner

recp commented Apr 21, 2019

note I noticed 1 failed test result in bezier (pulled from the tip).

this is weird, it passes on my local macos and macos on the travis-ci. My Linux VMs are not working for now, after fixed that I'll test it on Linux

@haxpor
Copy link
Copy Markdown
Contributor Author

haxpor commented Apr 22, 2019

I pulled down the tip from fix_82 branch again. I got the same result as before.

[       OK ] test_vec4
[ RUN      ] test_vec3
[       OK ] test_vec3
[ RUN      ] test_affine
[       OK ] test_affine
[ RUN      ] test_bezier
[  ERROR   ] --- glm_eq(smc, Bs_plain)
[   LINE   ] --- test/src/test_bezier.c:54: error: Failure!
[  FAILED  ] test_bezier
[==========] 12 test(s) run.
[  PASSED  ] 11 test(s).
[  FAILED  ] 1 test(s), listed below:
[  FAILED  ] test_bezier

 1 FAILED TEST(S)
FAIL test/tests (exit status: 1)

@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage decreased (-0.008%) to 11.081% when pulling e909c82 on haxpor:fix_82 into 73e6b65 on recp:master.

@recp
Copy link
Copy Markdown
Owner

recp commented Apr 27, 2019

SMC is matrix and vector multiplication. So there may be rounding errors, because SIMD registers (SSE/AVX....) do not have enough precision like single FPU... I was used this:

assert_true(glm_eq(smc, Bs_plain));
assert_true(glm_eq(Bs,  smc));

it must be:

test_assert_eqf(smc, Bs_plain);
test_assert_eqf(Bs,  smc);

Now all tests are passed.

@recp recp merged commit 85ca81c into recp:master Apr 27, 2019
@recp
Copy link
Copy Markdown
Owner

recp commented Apr 27, 2019

@haxpor thanks for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants