topic Binary operators a%b and a/b in SSE2 in IntelĀ® ISA Extensions
https://community.intel.com/t5/Intel-ISA-Extensions/Binary-operators-a-b-and-a-b-in-SSE2/m-p/774369#M190
There are no div or mod on integers in SSE2 (or any SSE extension)<BR />if the numbers are known to have limitedabs value(<2^24), you can convert to float and back to get the div result. mod can be derived from the div result using mul and sub (if you have negative numbers this can be trickier).<BR />if you don't have range limits on the in (assuming 32 bit ints), you need to upconvert to values to doublesand than do 2 doubledividesFri, 23 Jul 2010 22:11:22 GMTneni2010-07-23T22:11:22ZBinary operators a%b and a/b in SSE2
https://community.intel.com/t5/Intel-ISA-Extensions/Binary-operators-a-b-and-a-b-in-SSE2/m-p/774368#M189
Does sse2 use binary operators % and /? how would i write<BR />int x=k%p; //%modulus operator<BR />int y=a/b; // eg 9/4 is equal to 2 and not 2.25 ?Fri, 23 Jul 2010 15:13:44 GMThttps://community.intel.com/t5/Intel-ISA-Extensions/Binary-operators-a-b-and-a-b-in-SSE2/m-p/774368#M189Smart_Lubobya2010-07-23T15:13:44ZBinary operators a%b and a/b in SSE2
https://community.intel.com/t5/Intel-ISA-Extensions/Binary-operators-a-b-and-a-b-in-SSE2/m-p/774369#M190
There are no div or mod on integers in SSE2 (or any SSE extension)<BR />if the numbers are known to have limitedabs value(<2^24), you can convert to float and back to get the div result. mod can be derived from the div result using mul and sub (if you have negative numbers this can be trickier).<BR />if you don't have range limits on the in (assuming 32 bit ints), you need to upconvert to values to doublesand than do 2 doubledividesFri, 23 Jul 2010 22:11:22 GMThttps://community.intel.com/t5/Intel-ISA-Extensions/Binary-operators-a-b-and-a-b-in-SSE2/m-p/774369#M190neni2010-07-23T22:11:22Z