¡@

Home 

c# Programming Glossary: ecx

Why is String.IsNullOrEmpty faster than String.Length?

http://stackoverflow.com/questions/10360370/why-is-string-isnullorempty-faster-than-string-length

ebp esp 00000003 sub esp 8 00000006 mov dword ptr ebp 8 ecx 00000009 cmp dword ptr ds 00153144h 0 00000010 je 00000017 00000012.. 0 00000010 je 00000017 00000012 call 64D85BDF 00000017 mov ecx dword ptr ebp 8 0000001a call 63EF7C0C 0000001f mov dword ptr.. ebp esp 00000003 sub esp 8 00000006 mov dword ptr ebp 8 ecx 00000009 cmp dword ptr ds 001E3144h 0 00000010 je 00000017 00000012..

Why does adding local variables make .NET code slower

http://stackoverflow.com/questions/10369421/why-does-adding-local-variables-make-net-code-slower

0 00000037 mov eax edx 00000039 and eax 0Fh 0000003c xor ecx ecx 0000003e test eax eax 00000040 sete cl count isMultipleOf16.. 00000037 mov eax edx 00000039 and eax 0Fh 0000003c xor ecx ecx 0000003e test eax eax 00000040 sete cl count isMultipleOf16.. 00000055 lea r8d rbx rax count i 16 0 1 0 00000037 mov eax ecx 00000039 and eax 0Fh 0000003c je 0000000000000042 0000003e xor..

Is there a way to see the native code produced by theJITter for given C# / CIL?

http://stackoverflow.com/questions/1945719/is-there-a-way-to-see-the-native-code-produced-by-thejitter-for-given-c-sharp

0 divide divided by 3 1 i ThreeDivider i 00000283 idiv eax ecx And it knows you have to divide to divide by 3. Console.WriteLine.. i 3 Divider i 4 00000345 sar eax 1 ... 00000370 idiv eax ecx ... 00000395 sar esi 2 It has inlined the method and worked.. like this 0000000a mov edx 2 0000000f mov eax dword ptr ecx 00000011 call dword ptr eax 000000BCh Yup it evaluated the result..

Are these objects's references on the Stack or on the Heap?

http://stackoverflow.com/questions/2559271/are-these-objectss-references-on-the-stack-or-on-the-heap

we allocate heap memory for the new object. A a1 new A mov ecx 382518h call FFE6FD30 That returns a reference to a heap object.. reference we just stored on the stack and copy it into ecx which will be used for the this pointer to the call to the ctor... be used for the this pointer to the call to the ctor. mov ecx dword ptr ebp 48h Now we call the ctor. call FFE8A518 Now we..

x86/x64 CPUID in C#

http://stackoverflow.com/questions/3216535/x86-x64-cpuid-in-c-sharp

buffer eax level cpuid buffer 0 eax buffer 4 ebx buffer 8 ecx buffer 12 edx private readonly static byte x86CodeBytes 0x55.. mov dword ptr edi 4 ebx 0x89 0x4F 0x08 mov dword ptr edi 8 ecx 0x89 0x57 0x0C mov dword ptr edi 12 edx 0x5F pop edi 0x5B .. Save rdx buffer addy to r8 0x49 0x89 0xd0 mov r8 rdx Move ecx level to eax to call cpuid call cpuid 0x89 0xc8 mov eax ecx..