News for hackers. Stuff that matters.
Re:Visual x86 emulator by strommen on Monday June 08, 2015 @04:05PM (#9681993)
Nice work, this is really cool!

But I'm kinda missing the point. I think it would be very helpful to put some corresponding C (or pseudo-C) code. I understand assembly, but it would take me forever to parse out what this program does.

Also, a few design issues (on Windows 8, Chrome):

- The bold font in the registers is difficult to read.

- The dark colors (blue and maroon) in the register names are difficult to read.

- The columns of the register table don't quite line up with their headers.

Re:Visual x86 emulator by thlorenz on Monday June 08, 2015 @04:09PM (#9682024)
> I think it would be very helpful to put some corresponding C (or pseudo-C) code

That's not the point. All this is trying to show is how assembly and a CPU works. Understanding the program is secondary.

Additionally there is no C code for this as the assembly was written directly.

Re:Visual x86 emulator by pmalynin on Tuesday June 09, 2015 @01:43AM (#9684241)
Code is really not doing anything, it would be equivalent (in output that is) to he following code with some sort of optimization.

unsigned short data[8] = {0, 0, 0, 0, 0, 0, 0, 0};

for(int i=0;i<8;i++) {

   data[i] += 0xff1;
}

for(int i=0;i<8;i++) {

   data[i] += 1;
}

data[0] = 0x7fff;

data[0] += 1;

data[0] += 1;

And so on.

So yea, nothing special.

Re:Visual x86 emulator by thlorenz on Tuesday June 09, 2015 @11:17AM (#9686409)
More interesting snippets are coming once I can emulate more instructions. These are the ones it currently can do: https://github.com/thlorenz/visulator/tree/master/test/fixtu...

I agree though that a more interesting example would be nice and I'll try to come up with one even with what it can do now.

Re:Visual x86 emulator by thlorenz on Monday June 08, 2015 @04:08PM (#9682011)
Please file an issue on github, so I can track these problems and fix them. As I mentioned I'm color blind and could use some styling help via a pull request :)
Re:Visual x86 emulator by thlorenz on Monday June 08, 2015 @04:40PM (#9682221)
I addressed the styling issues you pointed out @strommen. If you still have problems reading things please supply a fix via a pull request.
Re:Visual x86 emulator by andrewstuart2 on Monday June 08, 2015 @05:43PM (#9682670)
I mean, you could always compile some yourself. Separation of concerns and what not.