↧
Answer by j6t for How is this function's assembly implementing the conditional?
Consider the two cases:(1) a is equal to b.Then foo(i) and bar(i) must be invoked in this order. The code does so. Since the return value of bar(i) is the same as that of foo(i), it is sufficient to...
View ArticleAnswer by 3CxEZiVlQ for How is this function's assembly implementing the...
return a == b ? a : b; is same as return a == b ? b : b; is same as return b;.
View ArticleHow is this function's assembly implementing the conditional?
The following code,int foo(int);int bar(int);int foobar(int i) { int a = foo(i); int b = bar(i); return a == b ? a : b;};with GCC trunk is compiling to this assembly:foobar(int): push rbx mov ebx, edi...
View Article
More Pages to Explore .....