Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Debug is not working in Ubuntu 12.04 64bit #2

Closed
mbakulin opened this issue Aug 5, 2013 · 1 comment
Closed

Debug is not working in Ubuntu 12.04 64bit #2

mbakulin opened this issue Aug 5, 2013 · 1 comment
Assignees
Labels

Comments

@mbakulin
Copy link

mbakulin commented Aug 5, 2013

Can't start debugging on this code:

%include 'io.inc'

section .bss
n resb 1
section .rodata

section .data

section .txt
global CMAIN
CMAIN:
GET_UDEC 4, [n]
mov ebx, 0
.for1:
cmp ebx, dword[n]
jae .for1break

GET_UDEC 4, eax
call div3
cmp eax, 0
jne .if1else
PRINT_STRING `YES\n`
jmp .if1break

.if1else:
PRINT_STRING NO\n
.if1break:

inc ebx
jmp .for1

.for1break:
mov eax, 0
ret

div3:
push ebp
mov ebp, esp

mov ecx, 3
mov edx, 0
div ecx
mov eax, edx ;if delitsa, then eax == 0

mov esp, ebp
pop ebp
ret
@ghost ghost assigned Dman95 Aug 21, 2013
@Dman95
Copy link
Owner

Dman95 commented Aug 30, 2013

Thanks for report! After adding quotes on 26 line (PRINT_STRING NO\n) and replacement of "section .txt" on correct "section .text" debugging works properly. Also I added error message when code contains wrong variant: "section .txt".

@Dman95 Dman95 closed this as completed Aug 30, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants