Why C++ compiles slowly
bearophile
bearophileHUGS at lycos.com
Wed Aug 25 04:22:49 PDT 2010
Jacob Carlborg:
> According to the ABI pure should already be in the mangled name (don't
> know if dmd follows that though). The mangled form looks like this:
>
> FuncAttrPure:
> Na
Yes, it's there:
import std.c.stdio: printf;
int function1(int x) {
return x * 2;
}
pure int function2(int x) {
return x * 2;
}
void main() {
printf("%d\n", function1(10));
printf("%d\n", function2(10));
}
_D5test29function1FiZi comdat
enter 4,0
add EAX,EAX
leave
ret
_D5test29function2FNaiZi comdat
assume CS:_D5test29function2FNaiZi
enter 4,0
add EAX,EAX
leave
ret
Bye,
bearophile
More information about the Digitalmars-d
mailing list