Author Topic: VUCOMISS is AVX  (Read 191 times)

aw27

  • Member
  • ****
  • Posts: 697
VUCOMISS is AVX
« on: July 31, 2017, 09:43:11 PM »

1) Why are you using Avx instructions in your real number comparisons without the user setting Avx in Options:

.if(xmm0 < FP4(1.5))
.endif

;vucomiss xmm0,dword ptr [extdef64+0x3000 (00000001`3f9b3000)]

2) Why it does not work in 32-bit mode?

.if(xmm0 < FP4(1.5))
.endif

; Error A2272: real or BCD number not allowed

johnsa

  • Member
  • ****
  • Posts: 519
    • Uasm
Re: VUCOMISS is AVX
« Reply #1 on: August 01, 2017, 12:07:36 AM »
OPTION ARCH:AVX is the default, if you want UCOMISS then set OPTION ARCH:SSE

I'll have a look now at the 32bit version.

aw27

  • Member
  • ****
  • Posts: 697
Re: VUCOMISS is AVX
« Reply #2 on: August 01, 2017, 01:08:40 AM »
OPTION ARCH:AVX is the default, if you want UCOMISS then set OPTION ARCH:SSE

I'll have a look now at the 32bit version.
All right, I always thought the default should be SSE but I can handle that.

habran

  • Member
  • *****
  • Posts: 1107
    • uasm
Re: VUCOMISS is AVX
« Reply #3 on: August 01, 2017, 08:21:49 AM »
Thanks aw27 :t
Another good find ;)
32bit macros were not initialising because CPU is dumb and can not follow our line of thoughts, no imagination that poor thing :icon_rolleyes:
Johnsa will upload fixed version as soon as he wakes up :biggrin:
« Last Edit: August 01, 2017, 06:54:28 PM by habran »
Cod-Father

johnsa

  • Member
  • ****
  • Posts: 519
    • Uasm
Re: VUCOMISS is AVX
« Reply #4 on: August 01, 2017, 06:44:37 PM »
Fixed and packages/repository updated.

There was a bug in the 32bit MEMALLOC macro which is fixed as well as the wrong macrolib init running as Habran mentioned which was causing FP4 to not be evaluated inside the .if ( ) expansion in 32bit.