Say i have this 10,000,000 (10 million) byte file.

I want to perform multiplication,addition and few other operation on all those bytes(total of 5). And after it is done say if i want to repeat the addition and other operations on the same file like a loop,then

How many such instructions can i execute in a programming language like c++?

Also when they say instructions,does one instruction count as a operation on every bit or byte or does it mean an actuall addition operation ?? and how does cycles and hertz fit inside all of this ??

I really want to know how much a processor can compute in a second,so

Thankyou and have a new year..

Ofcourse you know how much it can compute in a second.. Just find the amound of hertz.

Say i have this 10,000,000 (10 million) byte file.

I want to perform multiplication,addition and few other operation on all those bytes(total of 5). And after it is done say if i want to repeat the addition and other operations on the same file like a loop,then

How many such instructions can i execute in a programming language like c++?

Also when they say instructions,does one instruction count as a operation on every bit or byte or does it mean an actuall addition operation ?? and how does cycles and hertz fit inside all of this ??

I really want to know how much a processor can compute in a second,so

Thankyou and have a new year..

I can't give you actual numbers, but I can explain the theory for you...

MIPS and Hertz are semi-related but they are neither directly comparable nor equivalent units. I'll explain below...

A processor clock speed value of 1-Hz is 1 processor cycle per second. Therefore, if you have a 1.0GHz processor the processor completes approximately 1,000,000,000 (1-billion) cycles per second.

At the machine level, an instruction is a single binary code that sends a command to the processor. The minimum bit count of a single code is dependent on the processor's architecture, but is usually either 8- or 16- bits. A single high-level statement in a programming language (such as C++) may be represented by hundreds, or even thousands, of machine-level instructions.

All modern processors are capable of processing at least 32+ bits per clock cycle, and most can process 64 bits (how many are actually used depends on your O/S). Based on an average size of 8-bits per code/instruction, at 32 bits that is 4 instructions per cycle that the processor can execute. When you extend that out to a 1.0GHz processor, suddenly that becomes about 4,000,000,000 (4-billion) instructions per second. Since MIPS is short for Millions of Instructions Per Second you divide that number by 1,000,000 (1-million). So your MIPS value is about 4,000.

The actual numbers vary based on other technologies that the motherboard and processor have implemented such as hyper-threading, pipelining, multi-core, etc. but that's the basic idea.

I hope that helps.

Just find the amound of hertz.

Not entirely true.
"CPU instruction rates are different to clock frequencies, usually reported in Hz, as each instruction may require several clock cycles to complete or may be capable of executing multiple independent instructions at once. Additionally, the number of cycles required for instructions to complete is dependent upon the instruction being executed."
-http://en.wikipedia.org/wiki/Million_instructions_per_second#Million_instructions_per_second

EDIT: Fbody beat me to it with a better explanation! :)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.