testBug1.js 836 B

123456789101112131415161718192021
  1. //-------------------------------------------------------------------------------------------------------
  2. // Copyright (C) Microsoft Corporation and contributors. All rights reserved.
  3. // Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
  4. //-------------------------------------------------------------------------------------------------------
  5. function asmModule(stdlib, imports) {
  6. "use asm";
  7. var b8 = stdlib.SIMD.Uint16x8;
  8. var b8extractLane = b8.extractLane;
  9. var fround = stdlib.Math.fround;
  10. function testBug()
  11. {
  12. var a = b8(1, 0, 1, 0, 1, 0, 1, 0);
  13. var result = fround(0);
  14. result = fround(b8extractLane(a,0));
  15. return;
  16. }
  17. return {testBug:testBug};
  18. }
  19. var m = asmModule(this, {g1:SIMD.Bool16x8(1, 1, 1, 1, 1, 1, 1, 1)});