What does this line of assembly mean?
I disassembled an .exe file and got this as its first line. push ebp What does it mean? Why ebp? Does it have anything to do with pop command? even though I don't see it in the disassembly! ...
I disassembled an .exe file and got this as its first line. push ebp What does it mean? Why ebp? Does it have anything to do with pop command? even though I don't see it in the disassembly! ...
Suppose you've written a portable C++ code which runs smoothly on different platforms. To make some modifications to optimize performance, you use inline assembly inside your code. Is it a good practice (compiler optimization set aside) or will it make troubles for portability? ...
Hello, I would like to know this: Let's assume I let system allocate memory for an array e.g. MyArray. How then computer knows when I use this MyArray variable where to look? How are these named variables managed at low level? In short I want to know the relation between defined variable and physical address in memory. I hope you can...
I have a pointer to an array, DI. Is it possible to go to the value pointed to by both DI and another pointer? e.g: mov bl,1 mov bh,10 inc [di+bl] inc [di+bh] And, on a related note, is there a single line opcode to swap the values of two registers? (In my case, BX and BP?) ...
Is there any list of the hardware interrupts? i was coding a 16-bit app and i wanted to check some INTs but, i couldnt find anything usefull in google, can any1 provide me some docs about it? if possible, with details. Im sorry if its not a valid request but, its the only place that suits this question i think Thanks in advance ...
Hello everybody, I have a problem with g++ building an application which links to a static library, where the latter shall contain some global functions written in external asm-files, compiled with yasm. So in the library, I have #ifdef __cplusplus extern "C" { #endif extern void __attribute__((cdecl)) interp1( char *pSrc ); extern voi...
I tried to googled these, but failed. The msdn have the stackframe layout of arm on WinCE.msdn But It's not i want. ...
hi, I am working with an embedded board , but i don't know the flow of the start up code(C/assembly) of the same. Can we discuss the general modules/steps acted upon by the start up action in the case of an embedded system. Just a high level overview(algorithmic) is enough.All examples are welcome. /Kanu__ ...
Okay, so I understand all of us C/C++ programmers have at one time met our untimely nemesis, the diabolical signal SIGSEGV, the Segmentation Fault. Now, I understood (emphasis on the past tense) this to be some form of fail safe / checking system within some portion of the machine code spat out by the magical GCC (or g++) compiler, or wh...
Hi, can anyone give me a comprehensive description about ORG directive? When and why is it used in assembly written applications? Using Nasm on x86 or AMD64. ...
I know a little about assembly, and that there are 4 or 8 or so general purpose registers. How do all the programs on a computer work with just that amount of registers, especially with multithreading and everything? ...
I'm writing an 8086 assembler for a college project . I've gone through some material on compiler design on the internet and am reading the 'dragon book' of compilers . But the problem is I couldn't find much about the assembling (generating object code) part here . Are there any good books or links for assembler design . Where do I star...
Is it possible to insert assembly code on Visual C++ Express 2010 64 Bit? If not, is there an intrinsic for adc (add with carry)? ...
how to wrtie hai boot loader i know c and c++ please help me out ...
I am studying Intel Protected Mode. I found that Call Gate, Interrupt Gate, Trap Gate are almost the same. In fact, besides that Call Gate has the fields for parameter counter, and that these 3 gates have different type fields, they are identical in all other fields. As to their functions, they are all used to transfer code control into...
I am using Microsoft Visual C++ 2010. If I have a function like this: const char* blah(void); and I want to call it like this: __asm { call blah; ... } How do I get the return value of the function in the assembly? ...
I wrote a multi-threaded app to benchmark the speed of running LOCK CMPXCHG (x86 ASM). On my machine (dual Core - Core 2), with 2 threads running and accessing the same variable, I can perform about 40M ops/second. Then I gave each thread a unique variable to operate on. Obviously this means there's no locking contention between the th...
Hello, I have a complex problem to be solve, as I am stuck and found no way at all to solve this. Here's a code struct MyStruct { int x; float y; char c; }; void foo(MyStruct a_myStruct); int _tmain(int argc, _TCHAR* argv[]) { void *pMyStruct = malloc(sizeof(MyStruct)); int* pInt = (int*)pMyStruct; *pI...
Historically, why does it seem like just about everyone and their kid brother defined their own calling conventions? You've got C, C++, Windows, Pascal, Fortran, Fastcall and probably a zillion others I didn't think to mention. Shouldn't one convention be the most efficient for the vast majority of use cases? Is there ever any good re...
Low level languages and Assembly level langauges are machine dependent. My question is what does it mean? I mean is it dependent on the processor or features of machine like RAM, clock, etc. And how do high level langauges overcome this? ...