GithubHelp home page GithubHelp logo

bare68k's People

Contributors

cnvogelg avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

bare68k's Issues

Unable to build and install from source

@cnvogelg

I'm trying to install bare68k from a local repository using the following commands:

$ python setup.py install
$ python setup.py develop --user

Neither command works. I'm getting the following error:

/usr/bin/clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -pipe -I/opt/local/libexec/openssl11/include -Os -Ibare68k/machine_src -Ibare68k/machine_src/musashi -Ibare68k/machine_src/glue -Ibare68k/machine_src/gen -I/opt/local/Library/Frameworks/Python.framework/Versions/3.6/include/python3.6m -c bare68k/machine.c -o build/temp.macosx-10.13-x86_64-3.6/bare68k/machine.o
clang: error: no such file or directory: 'bare68k/machine.c'
clang: error: no input files
error: command '/usr/bin/clang' failed with exit status 1

I'm running Python 3.6.15 and clang 11 under Mac OS 10.13.

What's wrong?

Breakpoints

Thank you very much for bringing us this amazing library!

I'm trying to create an interactive debugger for exploring legacy 68k code based on bare68k.
While implementing breakpoints based on the built-in tools, I noticed that the code execution always stops at the next instruction AFTER the breakpoint location:

0x21a84	  *	LINK.W	A6, #$0
0x21a88	  X	MOVE.L	A3, -(A7)
0x21a8a		MOVEA.L	$8(A6), A3
0x21a8e		BSET.B	#$7, $C2C.W
0x21a94		CLR.L	(A3)

In the above code, the asterisk indicates the breakpoint location and "X" is the location where the execution actually halts.
I'm using the following code:

tools.set_breakpoint(0, addr, MEM_FC_SUPER_MASK, "BKPT1")
rt.run()
tools.disable_breakpoint(0)

When I set addr to 0x21a84, the execution actually stops at 0x21a88 as confirmed by the following log message:

2020-10-01 12:35:26,535          bare68k.handler:   INFO:  BREAKPOINT: @00021a84 #0 flags=SD data=BKPT1

PC=00021a88  SR=--S--210-----Z--
D0=00020400  D1=00000001  D2=00000000  D3=00000000
D4=00000000  D5=00000000  D6=00000000  D7=00000000
A0=00020404  A1=000239b2  A2=00000000  A3=00000000
A4=00020000  A5=00000000  A6=00000790  A7=00000790
USP=00000000 ISP=00000790 MSP=00000000 VBR=00000000

I'd like to make my debugger to behave just like GDB - the execution should halt at the specified location before executing the marked instruction.

What do I need to change to make it work?
Thank you in advance!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.