On Tue, Mar 2, 2010 at 10:55 AM, Andrew Haley wrote:
> On 03/02/2010 08:55 AM, Alain Ketterlin wrote:
>>
>> It looks like gcc sometimes produces "useless" conditional branches.
>> I've found code like this:
>>
>> xor %edx,%edx
>> ; code
Andrew Haley wrote:
On 03/02/2010 08:55 AM, Alain Ketterlin wrote:
It looks like gcc sometimes produces "useless" conditional branches.
I've found code like this:
xor%edx,%edx
; code with no effect on edx (see full code below)
test %edx,%edx
jne
The branch o
On 03/02/2010 08:55 AM, Alain Ketterlin wrote:
>
> It looks like gcc sometimes produces "useless" conditional branches.
> I've found code like this:
>
> xor%edx,%edx
> ; code with no effect on edx (see full code below)
> test %edx,%edx
> jne
Alain Ketterlin wrote:
> I've found code like this:
>
> xor %edx,%edx
> ; code with no effect on edx (see full code below)
> test %edx,%edx
> jne
I have experienced similar sequences where your
"code with no effect" was a lot of SSE instructions,
so I can confirm that the problem exi
It looks like gcc sometimes produces "useless" conditional branches.
I've found code like this:
xor%edx,%edx
; code with no effect on edx (see full code below)
test %edx,%edx
jne
The branch on the last line is never taken. Why does gcc generate such
code seq