Code: Show/Hide int main() {
while (1) { ; } } |
Code: Show/Hide while 1: pass |
Code: Show/Hide .org 0E00h
start: MVI C,0FFh NOP DCR C JZ start .end |
Code: Show/Hide while(1); |
Code: Show/Hide 100 Go 100 |
Code: Show/Hide >< |
Code: Show/Hide ; |
Code: Show/Hide pass |
Code: Show/Hide NOP |
Code: Show/Hide HANDLE h;
h = CreateObject(CONTINUUM_40); WaitForSingleEvent(h, INFINITE); |
Mr Ekted wrote: | |
|
50% Packetloss wrote: |
-C Bob: goto Bob; |
50% Packetloss wrote: |
Every program does something, even NOP increments the program counter |
D1st0rt wrote: |
for(int i = 1; i > 0; i++) |
50% Packetloss wrote: |
Every program does something, even NOP increments the program counter |
Code: Show/Hide DO LOOP |
Mr Ekted wrote: |
[..]
EB FE doesn't increment the program counter. |
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: |
What's EB FE? |
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: |
Usually NOP is used to wait 4 cpu clock cycles...Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... |
Mr Ekted wrote: |
Writing code that assumes a certain number of cpu clocks is very bad. |
Mr Ekted wrote: |
[..]
NOP has never taken 4 clock cycles. Pentium it is less than 1, 486 was 1, 386/286/86 was 3. Writing code that assumes a certain number of cpu clocks is very bad. |
Code: Show/Hide <?php
// ?> |
Code: Show/Hide int i = 3324; i = 15; i /= 3; i *= 4; i /= 10; i--; while (i == 1) { char moo[20]; char *a; strcpy(moo, "Mooo!"); a = &*moo; a += i; itoa(*a, moo, 10); a = &*moo; for (int x=0;x<=1;x++) a++; i = atoi(a); } |
Helicon wrote: |
[..]
this just runs until the int ceiling value... it stops |
Dr Brain wrote: |
But technicly, even code that is doing nothing is doing something. It's doing nothing, and nothing is something.
Everything is something, even nothing. And if you think I have a lot of things (like nothing, everything, and something) in this post, you have another thing coming. |
Grelminar wrote: |
((call/cc (lambda (x) (x x))) (call/cc (lambda (x) (x x))))
|
Code: Show/Hide lbl: jmp lbl |
50% Packetloss wrote: |
What is a EB FE anyway? A Wait for Interupt? |
Mr Ekted wrote: |
It's Intel machine code for:
label: jmp label |
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: | |
Why would
ever inc the PC? There's no sense in it... I think... ![]() Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... |
Code: Show/Hide Here: goto Here; |
Mr Ekted wrote: |
[..]Well, internally what happens is once an instruction is loaded--in this case 2 bytes--the program counter (called EIP in Intel) is advanced 2 bytes. Then the instruction is executed. This instruction basically says EIP = EIP - 2. So the actual increment and decrement does occur in the micro-code. |