Re: improvement of index-calculation
- From: "Guenther Wimpassinger" <gw_spam@xxxxxxxxx>
- Date: Thu, 28 Jul 2005 10:47:45 +0200
"Guenther Wimpassinger" <gw_spam@xxxxxxxxx> schrieb
>
> "Guenther Wimpassinger" <gw_spam@xxxxxxxxx> schrieb
>
> > mov ECX,[ESI+iShiftMaskY_sub_X_sub_Y32Bit]
> > shl EAX,CL // EAX := "masked y" shl
> > // iShiftMaskY_sub_X_sub_Y32Bit
>
> I have a small problem with the above statments. specially
> the shl. iShiftMaskY can be negativ. but shl treats cl always
> as an unsigned value and shift EAX 255 times left.
>
> do I have to check the and make a brachn like
>
> if EAX<0
> then
> neg cl
> shr eax,cl
> else
> shl eax,cl
>
> what is the most efficient way?
>
I have solved it this way, is there a better/shorter/faster way to do this?
TIA
Guenther
.
- References:
- improvement of index-calculation
- From: Guenther Wimpassinger
- Re: improvement of index-calculation
- From: Guenther Wimpassinger
- Re: improvement of index-calculation
- From: Guenther Wimpassinger
- improvement of index-calculation
- Prev by Date: Re: improvement of index-calculation
- Next by Date: Re: Fastcode MM B&V 0.47
- Previous by thread: Re: improvement of index-calculation
- Next by thread: Benchmark App
- Index(es):