instructions

How many asm-instructions per C-instruction?

I realize that this question is impossible to answer absolutely, but I'm only after ballpark figures: Given a reasonably sized C-program (thousands of lines of code), on average, how many ASM-instructions would be generated. In other words, what's a realistic C-to-ASM instruction ratio? Feel free to make assumptions, such as 'with curre...

Recursive assembly Call though no recursion in source code

I have a code fragment from a dump which I want to understand. What bothers me most, are the (seemingly) recursive calls like bd604: e8 fc ff ff ff call bd605 + 0xb5 What do they do? I don't use recursion in the original function. Thanks@schnaader it seems as if the calls make cld and jump to EAX EDIT: full dmp of my func...

equivalent number of instruction

Hi everybody, I've a question (just like me)... but...if I've a choosen algorithm written in C or C++ or whatever code you want...fixed a compiler I can determine the number of instructions but these intructions are different each other: x ADD, y MUL, z MOV, f FADD, t FMUL (F stands for FLOATING)...Is there a methodology or equation or ...

Average instruction time

Lets say we have an average of one page fault every 20,000,000 instructions, a normal instruction takes 2 nanoseconds, and a page fault causes the instruction to take an additional 10 milliseconds. What is the average instruction time, taking page faults into account? ...

64 bits assembly's instructions of 32 bits ones

I am beginning to port a program which is written in C and have several pieces of code written in assembly with instructions for a 32 bit machine - like ljmp - to a 64 bits machine. Is there a place/document that have the instructions, in assembly, for a 32 bit machine and its counterpart for a 64 one? If not, where can I find a documen...

Profiling instructions

I want to count several cpu instructions in my code. e.g. I would like to know how many additions, how many multiplications, how many float operations, how many branches my code executes. I currently use gprof under Linux for profiling my c++ code but it only gives the number of calls to my functions, and I manually estimate the number o...

Code that causes physical effects in hardware?

A couple of years ago, I remember reading about an academic project that executed a specific sequence of instructions whose effect was to cause the targeted processor to catastrophically overheat and fail, by exceeding the tolerance limits of the processor's design. It was interesting because it was the only example I've ever seen of a p...

Turing Machine Instruction Table

Hi! The definitions of Turing Machine say that it is prohibited for one to read/modify it's instruction table (program). Exactly, Turing Machine has no access to it's own program. What benefits can be achieved if one could weaken this restriction? If a machine could analise and/or modify it's program. Would that extend the class of tu...

How exactly do executables work?

I know that executables contain instructions, but what exactly are these instructions? If I want to call the MessageBox API function for example, what does the instruction look like? Thanks. ...

Assembler and Jump instruction (how does it work)

How does jump works ? Does it set the IP register or does it increase it ?? Is it relative or absolute change of place were we execute the code? ...

measure time to execute single instruction

Dear all, Is there a way using C or assembler or maybe even C# to get an accurate measure of how long it takes to execute a ADD instruction? ...

How many instructions to access pointer in C?

Hi All, I am trying to figure out how many clock cycles or total instructions it takes to access a pointer in C. I dont think I know how to figure out for example, p->x = d->a + f->b i would assume two loads per pointer, just guessing that there would be a load for the pointer, and a load for the value. So in this operations, the point...

Should a developer be a designer?

I have been developing websites for quite some time and I am not so good in designing websites? My Boss is refering me to take some lessons on it. But I really want to stick to development rather than designing? ...

Tracing/profiling instructions

I'd like to statistically profile my C code at the instruction level. I need to know how many additions, multiplications, divisions, etc I'm performing. This is not your usual run of the mill code profiling requirement. I'm an algorithm developer and I want to estimate the cost of converting my code to hardware implementations. For this...

Instructions Package for Java

I want to make a help/instructions page for my Java program but I really don't want to have to go through and program all the frames and searching and such. Is there a package or program that I can just insert the data into and it will read it and create the dialog? I couldn't seem to find anything about it on Google. It doesn't have ...

actions vs. avm instructions in actionscript

My questıon is that, what are actions and what are avm instructions. I've been reading these two documents: http://www.adobe.com/devnet/swf/pdf/swf_file_format_spec_v10.pdf http://www.adobe.com/devnet/actionscript/articles/avm2overview.pdf but I couldn't get the concept of it. Could anyone with more understanding of it explain this pl...

Access to data, BSS segments will be through using a pointer or by intructions directly addressing ?

I know when it's a matter of accessing memory of a stack frame it'll be through using stack frame pointer but I wonder about how the access to data, BSS segments containing global/static data will be, through using a pointer like stack frame pointer indicating starting point of those segments or instructions address pieces of those segme...

LEAL Assembler instruction

I have the following instruction and I'd like to know what the function is of the 0x10 in regards to this LEAL instruction? Is it a multiply or addition or is something else? leal 0x10(%ebx), %eax Can someone please clarify? This is x86 assembler on a Linux box. ...